You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commons-dev@ws.apache.org by "Davanum Srinivas (JIRA)" <ji...@apache.org> on 2006/02/02 21:50:03 UTC
[jira] Reopened: (WSCOMMONS-1) XmlSchema not resolving
schemaLocation with a relative path
[ http://issues.apache.org/jira/browse/WSCOMMONS-1?page=all ]
Davanum Srinivas reopened WSCOMMONS-1:
--------------------------------------
oops! my solution was 1.5 specific :(
> XmlSchema not resolving schemaLocation with a relative path
> -----------------------------------------------------------
>
> Key: WSCOMMONS-1
> URL: http://issues.apache.org/jira/browse/WSCOMMONS-1
> Project: WS-Commons
> Type: Bug
> Components: XmlSchema
> Environment: Windows XP, JRE 1.42
> Reporter: John Kaputin
>
> A relative path specified for the schemaLocation on xs:import and xs:include is not being resolved correctly. Seems to be because the base URI is not initialized.
> In this SchemaBuilder method, collection.baseURI is null:
> XmlSchema getXmlSchemaFromLocation(String schemaLocation) {
> //check and determine the nature of the schema reference
> //if it's relative and a base URI is present, then the schema
> //location needs to be taken by concatanting the base URI with the
> //relative path
> String baseURI = collection.baseUri;
> if (baseURI!=null){
> if (!isAbsoulte(schemaLocation)){
> schemaLocation = baseURI +
> (schemaLocation.startsWith("/")?"":"/")+
> schemaLocation;
> }
> }
> return collection.read(new InputSource(schemaLocation), null);
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira