Paul Libbrecht wrote:

I think Digester.parse(java.io.File) should do it for me, or?
(this method does build an input-source with correct URL, btw)
There's even, in the maven code, efforts towards making this an absolute path.


In theory it should ... but if it doesn't, you can easily construct a URL for a file and use the technique I described.

But the problem remains: if you look at the code of Digester.java, there's nothing that keeps the URL of the file! And the call to the method configure() is without any parameter!

But that's a feature, not a bug :-). No code in Digester is necessary, because it's all handled by the SAX parser underneath.

I do think, contrary to what Robert claims, that XML-compliance requires relative-system-id-entities to be resolved completely as long as we have a URL.

Correct relative entity resolution also requires users to correctly utilize what the JAXP APIs provide. If you don't provide an absolute URL for the document being parsed, relative URL references will fail. If you do provide an absolute URL, entity references will work in a manner totally transparent to Digester, because this is a feature built in to the underlying SAX based parser.

paul

Craig


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to