ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@apache.org>
Subject Re: TaskAdapter and execute()
Date Mon, 25 Feb 2002 19:57:24 GMT
I would prefer you write a new <taskdef/> that worked with whatever rules you 
wanted to use and used your own adapter rather than growing ants base adapter

On Tue, 26 Feb 2002 06:03, costinm@covalent.net wrote:
> One of the changes I've made for better 'embedability' or
> integration of ant is in TaskAdatper, the ability to
> 'adapt' java beans using a different name for the execute method.
>
> For example, while most tomcat startup beans follow ant
> conventions and would work perfectly in ant, we follow
> the 'normal' java bean mechanisms with 'start()', 'stop()',
> etc as names for methods.
>
> The change ( you can find it in sandbox for now ) allows
> a different method to be used in the 'adapted' bean.
> In addition, it allows 'noop' beans to be used - i.e.
> the properties will be set and a ref registered, with no
> action on the bean itself ( the bean can be used by another
> bean using the ref ).  While this may not be a big deal
> ( adding an empty execute() is easy ), it helps for existing
> classes.
>
> Opinions ? There are few (negative) tests that assume an
> exception will be thrown if no execute() is found, and
> obviously the beans would not work with ant1.4 ( since
> it'll be a new feature ).
>
>
> Costin

-- 
Cheers,

Pete

---------------------------------------------------
"Wise men don't need advice. Fools don't take it." 
                        -Benjamin Franklin 
---------------------------------------------------


--
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