I
got a look at the dynamic properties code in the "Embed" proposal in the
Apache Ant tree, and it looks like it will do quite nicely. It's actually
better than I thought it was going to be: a AOP style interceptor pattern.
Basically you register an PropertyInterceptor that intercepts the property
get and set methods in a PropertyHelper class. This allows me to make properties
set inside of or called by the wizard task mutable without affecting the
rest of ant. There are also some more rather interesting
uses of the dynamic properties that are already in embed, the most interesting
being the use of JXPath in properties, so you can do a property like ${/target[name='init']/@description}
to get the description of the init task. Hopefully this will make the 1.6
release. I may start building Inst.Ant off of embed pretty soon, just as
soon ans I stop playing Neverwinter Nights... |