I'm having a problem using the Xerces-J to validate my XML file against a schema.
If I load the file by uri, then everything works fine (it references its own schema). However, this XML file may be included in a jarfile, and so I really want to load it via this.getClass().getResourceAsStream(...). That works fine like this: parser.parse(new InputSource(this.getClass().getResourceAsStream(REPOSITORY_FILENAME))); That works, except it no longer knows where to look for the schema file. I looked at using the properties: http://apache.org/xml/properties/schema/external-schemaLocation or http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation These both take a filename, which I don't have access to in the jar context. And, even if I'm able to avoid the jar context, I really want to avoid having a .properties file with "xmlLocation=blahblah" that has to be maintained by each developer. Is there another solution I'm missing? Perhaps one that allows me to specify a schema by an input stream? -Kevin Klinemeier __________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
