ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jose Alberto Fernandez" <jalbe...@cellectivity.com>
Subject RE: polymorphism (was Re: antlib)
Date Fri, 25 Apr 2003 11:39:53 GMT
> From: Stefan Bodewig [mailto:bodewig@apache.org]
> 
> 
> On Fri, 25 Apr 2003, peter reilly <peter.reilly@corvil.com> wrote:
> 
> > I do not see the problem here: suppose Path implements 
> >   dynamicElement(Path path)
> > 
> > one could do:
> > <javac>
> >    <classpath>
> >        <PathThatIgnoresBuildSysclassPathToTrickGump>
> >             <pathelement path="${classpath}"/>
> >        </PathThatIgnoresBuildSysclassPathToTrickGump>
> >    </classpath>
> > </javac>
> 
> I don't want to use it as nested element of <classpath>, but as nested
> element of <javac>.
> 
> Take <classfileset>/<zipfileset> and <dependset> as another example
> (where you can trick me ;-).
> 
> I want to be able to be able to use <classfileset> as <srcfileset> and
> <zipfileset> as <targetfileset> - or the other way around.
> 

Actually, peter trick may give us a hint on an easy way to achieve polimorphism.
We just need to provide a way on the basic core type implementations to delegate
all calls to a nested object (similar to what we do for refids).

With that and the roles we would get alot of functionality almost free of charge
and without any changes to the core engine (but roles of course).

Jose Alberto

Mime
View raw message