OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] Problem with relative paths when validating against xsd

[ Lists Home | Date Index | Thread Index ]

I should also note that this is in xerces_2_2_1.jar

Quoting robert@elastica.com:

> So I've got an application that runs inside Weblogic and validates xml
> against
> xml schema thus.
> 
> String noNamespaceSchemaLocation = "PricingService/" + commandName +
> "Command.xsd";
> 
>         saxParser.setProperty(
>                
> "http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation";,
>                 noNamespaceSchemaLocation);
> 
> 
> Now this relative URI is relative to the CWD which is the Weblogic domain
> directory.
> 
> What I don't understand is why this path is also necessary to validate
> relative
> paths for all the .xsd files that lie in this directory.
> 
> So I have Common.xsd, Types.xsd that are under PricingService and are reused
> in
> other .xsds that are also in PricingService but at runtime via <xsd:include
> this paths are resolved relative to CWD and not relative to where they are
> being included so I'm forced to specify <xs:include
> schemaLocation="PricingService/Common.xsd"/> instead of just <xs:include
> schemaLocation="Common.xsd"/> and this presents a problem in XMLSpy because
> XMLSpy wants to resolve all paths relative to where they are included from
> not
> from any notion of a CWD.
> 
> 
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
> 
> 
> -----------------------------------------------------------------
> The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> initiative of OASIS <http://www.oasis-open.org>
> 
> The list archives are at http://lists.xml.org/archives/xml-dev/
> 
> To subscribe or unsubscribe from this list use the subscription
> manager: <http://www.oasis-open.org/mlmanage/index.php>
> 
> 




----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS