Problems validating GML 3.0

Having trouble installing Oxygen? Got a bug to report? Post it all here.
Scott C

Problems validating GML 3.0

Post by Scott C »

I have a schema that is importing the GML 3.0 schema and am getting all kinds of errors in Oxygen when I try to validate my schema that come from GML 3.0's xsd files.

For instance, dynamicFeatures.xsd defines a complexType called TrackType that throws the following errors:

SystemID: http://schemas.opengis.net/gml/3.0.0/ba ... eature.xsd
Location: 75:33
Description: E rcase-RecurseLax.2: There is not a complete functional mapping between the particles.
URL: http://www.w3.org/TR/xmlschema-1/#rcase-RecurseLax

SystemID: http://schemas.opengis.net/gml/3.0.0/ba ... eature.xsd
Location: 75:33
Description: E derivation-ok-restriction.5.4.2: Error for type 'TrackType'. The particle of the type is not a valid restriction of the particle of the base.
URL: http://www.w3.org/TR/xmlschema-1/#deriv ... estriction

In all, I receive 86 validation errors when validating my schema, but in reality there are 44 pairs of the above mentioned errors in various GML 3.0 xsd files.

Here is the beginning of my schema with the import statement. Maybe I'm doing something wrong in my import statement?

<?xml version="1.0" encoding="UTF-8"?>
<!-- OceanWatch Schema v.1 -->
<xs:schema targetNamespace="http://sri.scpa.com/oceanwatch/namespace" elementFormDefault="unqualified" xmlns="http://sri.scpa.com/oceanwatch/namespace" xmlns:ow="http://sri.scpa.com/oceanwatch/namespace" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:gml="http://www.opengis.net/gml">
<xs:import namespace="http://www.opengis.net/gml" schemaLocation="http://schemas.opengis.net/gml/3.0.0/base/gml.xsd"/>

I'm a newbie to XML so I don't doubt that there is something I'm doing wrong and would appreciate any insights into this problem. Thanks!
Scott C
Posts: 1
Joined: Mon Jun 28, 2004 10:06 pm

for clarification

Post by Scott C »

Now that I've registered, I can edit my thoughts in this reply. There are, of course, 43 pairs of errors totalling 86 validation errors in all. Also, here is the definition of the trackType element from GML 3.0's dynamicFeatures.xsd file which throws the errors I mentioned in my original post:

<element name="track" type="gml:TrackType" substitutionGroup="gml:history"/>
<!-- ===================================== -->
<complexType name="TrackType">
<annotation>
<documentation xml:lang="en"> The track of a moving object is a sequence of specialized timeslices that indicate the status of the object. </documentation>
</annotation>
<complexContent>
<restriction base="gml:HistoryPropertyType">
<sequence>
<element ref="gml:MovingObjectStatus" maxOccurs="unbounded"/>
</sequence>
</restriction>
</complexContent>
</complexType>
george
Site Admin
Posts: 2095
Joined: Thu Jan 09, 2003 2:58 pm

Post by george »

Hi Scott,

We are using the latest version of Xerces to perform schema validation. This topic, validation problems on GML appeared a couple of times in the past and it is hard to tell if the problem is in the parser or in the schema, although I tend to think that it is in the schema.
The current solution is to turn off the schema full checking feature [1] and you should be able to work with GML.

[1] http://www.oxygenxml.com/doc/ug-oxygen/ ... arser.html

Best Regards,
George
Post Reply