ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Antoine Levy-Lambert" <levylamb...@tiscali-dsl.de>
Subject Re: antlib / proposal of Peter Reilly
Date Wed, 14 May 2003 10:19:09 GMT

----- Original Message -----
From: "Jose Alberto Fernandez" <jalberto@cellectivity.com>
To: "Ant Developers List" <dev@ant.apache.org>
Sent: Wednesday, May 14, 2003 11:49 AM
Subject: RE: antlib / proposal of Peter Reilly

I am trying simply to get some action done. I have also updated the proposal
under proposal/sandbox/antlib yesterday to cater for changes in Project.java
and ProjectComponent; the commit message got hit by the 100k limit.

>Well I have not given the fight on the need for roles and separate
>symbol-tables for different Types. I would like for someone to explain
>how <ejbjar>, <jspc>, <serverdeploy> can have vendor dependent
><weblogic>, <jboss>, etc. within this model.
Costin Manolache said we should make a separate proposal for roles,
including the possibility of defining roles as a normal task which you can
directly include in build files. Before we do this, there needs to be some
more discussion, because Costin says he would prefer that every class
implementing a particular interface be automatically usable in the
corresponding role. Or we need to organize one or several votes.



>> I am quoting Peter Reilly here :
>>
>> This patch adds 4 new features (the code is interrelated,
>> but may be split).
>>   * adapter attribute added to typedef
>>   * add(Type) method added to introspection rules
>>   * typedef can read an xml defintion file
>>   * namespace support for xml defintions (antlib:)
>> So one can do
>> <project xmlns:acme="org.acme.anttasks">
>>    <acme:hello>
>>       <path path="build.xml"/>
>>    </acme:hello>
>> </project>
>> where the class path contains the org/acme/anttasks/antlib.xml
>> and the antlib.xml file contains:
>> <antlib>
>>    <typedef name="hello" classname="org.acme.anttasks.Hello"/>
>> </antlib>
>>

>As I have mentioned before, I have problems with this. It means that
>users are forced to use name spaces even if there are no collisions
>on the names of the components in the antlib, just because there is no
>way to find the antlib.xml otherwise.

I do not think that having to use a prefix to indicate tasks or types coming
from a particular antlib is a huge constraint.
In JSP, if you use taglibs you have to use prefixes to indicate the
particular taglib you are using, such as <html:button>
Also, I am not sure whether the use of the prefix is required or not. (Peter
?)

>I do not see an <antlib> task specified in the project, does that
>means that I need to put all the jars in the classpath of ANT?
> I hope that is not a requirement. I think users need to be
>able to specify the classpath they want to use for their
>libraries just like they do for <taskdef>.

There is an antlib task in the project.

>
> ToDo: add in support for ant-type polymorphism and
> addConfigured(Type).
>       also more error checking and unit tests.
>

>ant-type polymorphism is not a priority for me, but
>addConfigured support is. Given the fact that the
>objects being passed are opaque for all purposes of
>the parent element, it makes little sense to pass an
>uninitialized object to the parent (which is what add(Type) does)
>instead of passing an initialized object (what addConfigured(Type)
>should do).

I need to check what happens with add and addConfigured exactly in this
proposal. I have the impression that actually both add and addConfigured are
accepted, but I do not know if there is something to say which of the two
versions has priority. Peter ?


>Jose Alberto

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


Mime
View raw message