ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Costin Manolache <cmanola...@yahoo.com>
Subject Re: [PATCH] Adding Dynamic elements for the n'th time
Date Wed, 27 Nov 2002 15:45:01 GMT
Magesh Umasankar wrote:

> ----- Original Message -----
> From: "Conor MacNeill" <conor@cortexebusiness.com.au>
> 
>> My original Ant 1 patch (which Magesh has cited) used a different
>> approach where it tried to guess which underlying method is to be used. I
>> haven't studied Magesh's patch in detail but for fully flexibly
>> polymorphism, you need to identify the type of the object being passed
>> and the method on the task to which you will pass it (i.e. two
>> independent things). Using only
> one
>> piece of information (the type name) has limits.
> 
> Yes.  If the method name to be used is also to be dynamic,
> we can make that happen as well - but, I think, going forward
> with baby steps will be easier.  If I start packing more and
> more into a single patch, the chances of its inner workings
> being debated in detail gets slimmer ;-)

As I said, I'm +1 on the original patch - I see it as an improvement
that can be further improved :-)

You know me - if something doesn't have a clear solution I usually
propose a hook :-)

We already have a number of hooks on element configuration, maybe the
way to go would be to extend those.

I have a use case: have introspection recognize ${dyn:properties} that
evaluate to objects, and call the right method ( instead of 
object->string->object conversion ). Another use case would be a more 
pluggable mechanism for the "property editors" ( the convertors between 
strings and real params ).

JMX introduces another set of use cases - if we want to support
JMX tasks using a task adapter, we'll need to use MBeanInfo and 
setAttribute to configure it. 

IMO it may be a good idea to find the best "extension points" and 
add hooks in the right place, and then play with different options
( some will be added to core, some may stay outside ).

Costin





--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message