Hello Gary,

When relying on the namespace instead of an explicit schema association (xsi:schemaLocation), Oxygen only associates one schema for the root element namespace of the XML instance. Any other namespaces from the XML instance are ignored.


Why do you consider using xsi:schemaLocation is a problem?
As long as you have an XML catalog that resolves the schema location, it doesn't really matter what location is being used.

Instead of using a canonical location, you could use the actual namespace as the schema location in xsi:schemaLocation and it would work in Oxygen.
e.g.
<oval_definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://oval.mitre.org/XMLSchema/oval-definitions-5 http://oval.mitre.org/XMLSchema/oval-definitions-5 http://oval.mitre.org/XMLSchema/oval-definitions-5#independent http://oval.mitre.org/XMLSchema/oval-definitions-5#independent" ...

The alternative is to modify the main XML schema (or create another main XML schema) to import all namespaces that are used in the XML instance.

Regards,
Adrian
Adrian Buza
oXygen XML Editor and Author Support

Tel: +1-650-352-1250 ext.2020
Fax: +40-251-461482

On 21.12.2015 14:56, Gary Gapinski wrote:
I am attempting (perhaps wrongly) to have OVAL document validation to occur based on namespace (without using xsi:schemaLocation).

I suspect my problem is related to the rather complex OVAL schemata relationships, but I have not determined how best (if at all) to accomplish this.

I have a sample document and a related XML catalog. The XML catalog has been configured in the project preferences.

When I attempt to validate the document, it appears that the schema in namespace http://oval.mitre.org/XMLSchema/oval-definitions-5#independent has not been associated. The primary (root) schema is associated and is obtained from the catalog.

If this sort of implicit association is not possible, any suggestions on how to knit together the many discrete (sub-)schemata of OVAL would be much appreciated. I would prefer to avoid the use of xsi:schemaLocation if at all possible (since a "canonical" location for such is not assured).

Regards,

Gary



_______________________________________________
oXygen-user mailing list
oXygen-user@oxygenxml.com
https://www.oxygenxml.com/mailman/listinfo/oxygen-user