Christopher Lenz wrote:
Nicola Ken Barozzi wrote:
Conor MacNeill wrote:
Christopher Lenz wrote:
Every JAR in $ANT_HOME/lib would be scanned for a descriptor in META-INF (for example; be it some XML format or a properties file), and that descriptor would contain a URI that needs to be used as XML namespace URI in the build file.
Hope I'm not totally off here... haven't followed much of the discussion before this thread.
No, spot on - that is what I had in mind.
I think too that this is the way, just with a change:
- Automatic antlib loads in ant.home/lib would be without namespace, as they are treated as "default" ones.
Not sure.
Rather than adding an additional "ext" dir to separate between the default antlibs (i.e. the set of tasks distributed with Ant) and external antlibs, why not have all default antlibs specify "http://ant.apache.org/" (for example) as their namespace URI. That would be the default namespace for buildfiles, of course.
External antlibs could still be placed in $ANT_HOME/lib, but would specify a different namespace URI in their descriptor.
Am I missing something?
Technically you are correct. MHO is that putting them in phisically different dirs is more evident to the users.
"This goes here, that goes there."
Just a possibility.
- Normal taskdef would be without namespace.
It'd be nice to be able to import "legacy" tasks into a namespace specified in the <taskdef>, though. Not sure how this would work, and it's not very important either ;-)
- <antlib> call would be with namespace.
Hmm.. can't parse this.. can you elaborate?
If I load tasks from an antlib, they get loaded with the namespace. The above to cases are about implicit loading, by putting jars in special dirs, this is about asking for it explicitly in the buildfile.
- We can add a ant.home/ext dir where antlib loads *with* namespace
As for a descriptor, being a Cocoon developer, and having used xml for so much time, I can only suggest... not to use it, simple properties like now is just good enough, just add a namespace property as suggested above. :-)
-- Nicola Ken Barozzi [EMAIL PROTECTED] - verba volant, scripta manent - (discussions get forgotten, just code remains) ---------------------------------------------------------------------
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
