You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by bu...@apache.org on 2002/02/03 23:42:14 UTC

DO NOT REPLY [Bug 6205] New: - Turned off validation and Parser fails, because it can not find the dtd.

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6205>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6205

Turned off validation and Parser fails, because it can not find the dtd.

           Summary: Turned off validation and Parser fails, because it can
                    not find the dtd.
           Product: Xerces2-J
           Version: 2.0.0
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: JAXP
        AssignedTo: xerces-j-dev@xml.apache.org
        ReportedBy: elite@chello.at


Used xerces 2.0 as parser, configured it with JAXP xml-factory.

Turned off validation with 

	XMLReader parser = 
(XMLReader)Class.forName(parserName).newInstance();

	parser.setFeature( 
"http://xml.org/sax/features/validation", false);
	parser.setFeature( 
"http://xml.org/sax/features/namespaces", true);
	parser.setFeature( 
"http://apache.org/xml/features/validation/schema", 
false);
	parser.setContentHandler(handler);
	parser.setErrorHandler(handler);
	parser.parse(resourceName);

Then 
parsed an xml-file which contains a reference to a dtd with a file-url like <!DOCTYPE 
vcf:configuration SYSTEM "file:///dev/schema/visualizer/visualizer.dtd"> Works fine, if 
the file ist there but the parser fails, if it can not find the dtd. I definitly did not expect that, 
since the validation was turned off (rather for performance reasons, but I also do not want to copy 
files to the dev-directory on unix-machines).

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