Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test 'verify GML Object Property Pattern' fails if property with type 'gml:TimePeriodType' exists #46

Closed
dstenger opened this issue Aug 15, 2016 · 2 comments
Assignees
Labels

Comments

@dstenger
Copy link
Contributor

dstenger commented Aug 15, 2016

Test 'verify GML Object Property Pattern' fails if a property with type 'gml:TimePeriodType' is returned by DescribeFeatureType request.

Example of DescribeFeatureType response:

...
  <element name="osm_protected_area" substitutionGroup="gml:AbstractFeature">
    <complexType>
      <complexContent>
        <extension base="gml:AbstractFeatureType">
          <sequence>
            <element name="osm_id" minOccurs="0" type="integer"/>
            <element name="boundary" minOccurs="0" type="string"/>
            <element name="leisure" minOccurs="0" type="string"/>
            <element name="name" minOccurs="0" type="string"/>
            <element name="tourism" minOccurs="0" type="string"/>
            <element name="osm_timestamp" minOccurs="0" type="dateTime"/>
            <element name="period" minOccurs="0" type="gml:TimePeriodType"/>
            <element name="way_area" minOccurs="0" type="decimal"/>
            <element name="geometry" minOccurs="0" type="gml:SurfacePropertyType"/>
          </sequence>
        </extension>
      </complexContent>
    </complexType>
  </element>
...

Following error message is returned:

Severity: ERROR Message: GML property cannot be a GML object: {http://www.deegree.org/app}period (in type null) Severity: ERROR Message: GML property cannot have ID type attribute: {http://www.deegree.org/app}period (in type null) Severity: ERROR Message: GML property cannot be a GML object: {http://www.deegree.org/app}period (in type null) Severity: ERROR Message: GML property cannot have ID type attribute: {http://www.deegree.org/app}period (in type null) 

GML 3.2.1 specification says following:

A.1.1.7 Property elements are not object elements
a) Test Purpose: Verify that all property elements in the GML application 
schema are not objects.

b) Test Method: Check the application schema that every child element of 
every object element is neither directly or indirectly in the substitution 
group of gml:AbstractObject.

c) Reference: ISO 19136:2007, 7.2.2, 21.2.5.

d) Test Type: Capability Test.

period is of type 'gml:AbstractGMLType' (when the hierarchy is resolved beginning at 'gml:TimePeriodType'). This does not mean that it is a 'gml:AbstractObject'. As 'gml:AbstractObject' is an abstract element it can just be inherited via substitutionGroup (which is not the case in the given example).

So, the test should not check if an element is inherited from 'gml:AbstractGMLType'. Instead, it should be tested whether an element is inherited from 'gml:AbstractObject'.

@dstenger dstenger added the bug label Aug 15, 2016
@rjmartell
Copy link
Contributor

rjmartell commented Sep 2, 2016

A temporal property element cannot itself be a GML object. Use gml:TimePeriodPropertyType. See Table 6: Predefined formal temporal property types.

<element name="period" minOccurs="0" type="gml:TimePeriodPropertyType" />

The property then looks like this in a feature instance:

<tns:period>
  <gml:TimePeriod xmlns:gml="http://www.opengis.net/gml/3.2" gml:id="TP-1">
    <gml:beginPosition>2016-06-30T12:51:29Z</gml:beginPosition>
    <gml:endPosition>2016-07-10T22:05:39Z</gml:endPosition>
  </gml:TimePeriod>
</tns:period>

@dstenger
Copy link
Contributor Author

We changed the type of "period" to "gml:TimePeriodPropertyType" as you proposed.

Now, test "verify GML Object Property Pattern" does not fail any more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants