ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: DirectoryScanner cache to boost performance
Date Tue, 15 Sep 2009 14:35:27 GMT
On 2009-09-15, Raja Nagendra Kumar <Nagendra.Raja@tejasoft.com> wrote:

> Thank you very much for this info. I am trying to use this in our custom
> task some thing like this

> Union lUnion = (Union) TaskUtils.getCurrentProject().getReference(
> 		    lRoot);
> 	    Restrict lRestrict = new Restrict();

...

> However, I am unable to find a way to get the values matching such an
> expression. After doing the above, I am expecting some method in lRestrict
> to find all the matching files.

It's called iterator() and returns an Iterator<Resource> (in Java5
terms, but Ant is still at Java 1.3 or 1.4 so it is a plain Iterator).

See the org.apache.tools.ant.types.ResourceCollection interface that is
implemented by Union, Restrict and all the others.

Stefan

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


Mime
View raw message