ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Antoine Levy-Lambert" <anto...@gmx.de>
Subject Re: Resource.getURL()
Date Thu, 21 Sep 2006 15:45:46 GMT
Hello Dominique,

in this case I would add getURL() to Resource, returning null,
and getURL() to FileResource returning file://.... and getURL() to ZipResource returning jar:file://...
.

Concerning the custom handlers, I will not do anything. This will be left to the developers
of custom resource implementations.

Regards,

Antoine
-------- Original-Nachricht --------
Datum: Thu, 21 Sep 2006 09:06:23 -0500
Von: "Dominique Devienne" <ddevienne@gmail.com>
An: "Ant Developers List" <dev@ant.apache.org>
Betreff: Re: Resource.getURL()

> > > Concerning custom URLProtocolHandler (s), I am not clear how this
> works ?
> > first you provide something that lets you open connections [...]
> 
> FTR, I'm not to fond of this idea of playing with custom URL protocols
> and/or handlers, at least as far as I correctly understood what it
> means.
> 
> I used to use one before <import> came along, using a resource:
> protocol to locate XML entity includes more flexibly, and it worked
> fine, except for the fact that it needed JVM args required during JVM
> startup. Installing the custom URL handler once the VM is already
> started is more involved, and if I remember correctly, involves having
> one's own factory for URL handlers, which is bound to conflict with
> Ant "containers" who also want to install their own.
> 
> I think when Resources where first introduced to Ant we briefly
> discussed why we needed them instead of using straight URLs, which is
> a well documented and extensible mechanism to access content, but an
> argument against using URLs was that extending URL protocols is not
> easy.
> 
> I'm fine with adding getURL to Resources, if it's an optional
> operation (returning null is not supported or throwing UOE but only is
> another supportsURL() boolean method is available), but I can't see
> the need for custom URL protocols. I'm open to arguments showing me
> where I'm wrong though, of course. --DD
> 

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


Mime
View raw message