You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Weber, Lance" <La...@McKesson.com> on 2003/01/21 22:11:49 UTC
Plugin Development Question
Hey guys, I finished a first cut at a basic SCM abstraction component (no,
really, I do!) and I'm trying to write a plugin to access it from Maven but
I'm stuck with a couple of questions.
I have an interface that exposes one or more methods with signatures like
public String myMethod(String parm1, String parm2, boolean parm3, boolean
parm4) throws Exception
1) Can jelly instantiate a concrete class as an instance of an interface?
2) Can jelly pass pararameters to a method call?
3) Can jelly return results from a method call?
Sorry if these are simple questions - I didn't see any good examples of the
above in the documentation or in the other plugins I looked at. Anyway,
thanks for any guidance.
--L
Lance Weber
McKesson Health Solutions
Chief Architect, Product Development
CareEnhance Services
___________________________________________________________________________
CONFIDENTIALITY NOTICE: This e-mail message, including any attachments, is
for the sole use of the intended recipient(s) and may contain confidential
and privileged information. Any unauthorized review, use, disclosure or
distribution is prohibited. If you are not the intended recipient, please
contact the sender by reply e-mail and destroy all copies of the original
message.
Re: Plugin Development Question
Posted by di...@multitask.com.au.
"Weber, Lance" <La...@McKesson.com> wrote on 22/01/2003 08:11:49 AM:
> Hey guys, I finished a first cut at a basic SCM abstraction component
(no,
> really, I do!) and I'm trying to write a plugin to access it from Maven
but
> I'm stuck with a couple of questions.
>
> I have an interface that exposes one or more methods with signatures
like
>
> public String myMethod(String parm1, String parm2, boolean parm3,
boolean
> parm4) throws Exception
>
> 1) Can jelly instantiate a concrete class as an instance of an
interface?
The core new tag allows you to create new objects. As for being an
'instance of an interface', I'm not sure what this means. See
http://jakarta.apache.org/commons/sandbox/jelly/tags.html#core:new for
more detail on new.
> 2) Can jelly pass pararameters to a method call?
${object.method(param)}
Where both object and param are in the jelly context.
> 3) Can jelly return results from a method call?
<j:set var="returnValue" value="${object.method(param)}" />
> Sorry if these are simple questions - I didn't see any good examples of
the
> above in the documentation or in the other plugins I looked at. Anyway,
> thanks for any guidance.
HTH,
--
dIon Gillard, Multitask Consulting
Blog: http://www.freeroller.net/page/dion/Weblog
Work: http://www.multitask.com.au