ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Loughran <ste...@apache.org>
Subject Re: svn commit: r531340 - /ant/core/trunk/src/main/org/apache/tools/ant/launch/Locator.java
Date Fri, 27 Apr 2007 09:28:18 GMT
Kevin Jackson wrote:
> Hi,
> 
> Looking deeper into this, the reason that the bug #42227 has appeared
> is because ImportTask uses Location which uses FileUtils.fromURI,
> which is using the new Locator.fromURI
> 

One thing I'm thinking of for <import> is how to resource enable it; 
which means we need a way (an interface) of opening a resource relative 
to another resource:

interface RelativeResource {

   Resource createResource(String relativePath);

}


We'd then have every build file knowing where it came from, and, if it 
came from a resource that implemented RelativeResource(), return a new 
resource.

<import file="../something.xml" /> would call 
FileResource.createResource("../something.xml"); on the local file, or, 
if it was loaded off a clasloader, 
ClassResource.createResource("../something.xml") would return something 
new in the classpath.

steve

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


Mime
View raw message