On Tue, 26 Feb 2002, Peter Donald wrote: > 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
This is a simple extension to the 'base' adapter. It is backward compatible. Adding a new Taskdef and a new TaskAdapter will just cause confusion and mess - and will be difficult to keep in sync with the original. By this logic we should have a new <zip> task when somebody adds a different attribute or functionality ? Costin > > On Tue, 26 Feb 2002 06:03, [EMAIL PROTECTED] 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 > > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
