> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]On Behalf Of Andrew
> Stevens
> Sent: 6. januar 2002 23:58
> To: [EMAIL PROTECTED]
> Subject: [Xdoclet-devel] DTD-based validation
>
>
> I was thinking of adding DTD validation support to the Castor stuff.  It
> looks pretty trivial, but I notice from their website that it's
> on version
> 0.9.3.9 and the DTD says "*Note*: This DTD is under evolution and subject
> to change.".  So, is it worth doing it yet or should we leave it until
> they reach a 1.0 release?
>
> Also, am I right in thinking the validator can use DTDs on a remote
> server? (I think this was the reason the DtdFilename parameter was added,
> to avoid looking for the remote DTD when there's no internet connection)
> If so, I think the shouldValidate() test in XmlSubTask should be changed.
>

The default behaviour of the XML parser is to look at the DTD URL in the
XML. -But XmlValidator overrides this behaviour. The reason is that you're
not always on the Internet when you build. Some build environments will
never be either.

> Currently we require the public ID and a filename to be set in
> order to do
> the validation; if I was using a custom XmlTemplate with my own DTD
> (specified in the subtask parameters), there may not be a public ID.  I
> ought to still be able to validate the generated XML, though.  Either the
> system ID will be the local filename, or maybe a URL for a server on the
> local network.  So, I think the public ID is irrelevant for
> whether or not
> we can validate, so long as there's either a DtdFilename or a system ID
> (with the filename taking precedence when there's both, to avoid the
> problems accessing remote DTDs without an internet connection).  I guess
> this may need changes to the validator's registerDTD (and possibly
> elsewhere too)?
>

Perhaps XmlValidator should use a File URL in stead of a file. That way, we
can support both File and net.

>
> Andrew.
>
> _______________________________________________
> Xdoclet-devel mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/xdoclet-devel


_______________________________________________
Xdoclet-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-devel

Reply via email to