org.opengis.cite.ogcapifeatures10.conformance.core.collections

## Class AbstractFeatures

- java.lang.Object
- - org.opengis.cite.ogcapifeatures10.conformance.CommonFixture
  - - org.opengis.cite.ogcapifeatures10.conformance.CommonDataFixture
    - - org.opengis.cite.ogcapifeatures10.conformance.core.collections.AbstractFeatures

- Direct Known Subclasses:
    Features, FeaturesBBox, FeaturesErrorConditions, FeaturesLimit, FeaturesTime

      public class AbstractFeatures
      extends CommonDataFixture

  Author:
    Lyn Goltz

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `protected class` | `AbstractFeatures.CollectionResponseKey`
    `protected class` | `AbstractFeatures.ResponseData`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected Map<AbstractFeatures.CollectionResponseKey,AbstractFeatures.ResponseData>` | `collectionIdAndResponse`
    `protected List<Map<String,Object>>` | `collections`
    `protected URI` | `iut`

    - ### Fields inherited from class org.opengis.cite.ogcapifeatures10.conformance.CommonDataFixture

      `noOfCollections`

    - ### Fields inherited from class org.opengis.cite.ogcapifeatures10.conformance.CommonFixture

      `requestLoggingFilter, responseLoggingFilter, rootUri`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractFeatures()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Iterator<Object[]>` | `collectionPaths(org.testng.ITestContext testContext)`
    `protected Boolean` | `isExplode(com.reprezen.kaizen.oasparser.model3.Parameter param)`
    `protected boolean` | `isRequired(com.reprezen.kaizen.oasparser.model3.Parameter param)`
    `void` | `retrieveRequiredInformationFromTestContext(org.testng.ITestContext testContext)`
    `(package private) void` | `validateFeaturesProperty(AbstractFeatures.CollectionResponseKey collection)` Abstract Test 22, Test Method 2
    `(package private) void` | `validateGeometriesInCrs84(AbstractFeatures.CollectionResponseKey collection)` Abstract Test 2, Test Method 1
    `(package private) void` | `validateLinks(AbstractFeatures.CollectionResponseKey collection)` Abstract Test 22, Test Method 4 (Abstract Test 23)
    `(package private) void` | `validateNumberMatched(AbstractFeatures.CollectionResponseKey collection)` Abstract Test 22, Test Method 6 (Abstract Test 25)
    `(package private) void` | `validateNumberReturned(AbstractFeatures.CollectionResponseKey collection)` Abstract Test 22, Test Method 7 (Abstract Test 26)
    `void` | `validateTimeStamp(AbstractFeatures.CollectionResponseKey collection)` Abstract Test 22, Test Method 5 (Abstract Test 24)
    `void` | `validateTypeProperty(AbstractFeatures.CollectionResponseKey collection)` Abstract Test 22, Test Method 1

    - ### Methods inherited from class org.opengis.cite.ogcapifeatures10.conformance.CommonDataFixture

      `createListOfMediaTypesToSupportForFeatureCollectionsAndFeatures, createListOfMediaTypesToSupportForFeatureCollectionsAndFeatures, createListOfMediaTypesToSupportForOtherResources, getApiModel, noOfCollections, requirementClasses, retrieveApiModel`

    - ### Methods inherited from class org.opengis.cite.ogcapifeatures10.conformance.CommonFixture

      `clearMessages, getRequest, getResponse, init, initCommonFixture`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### collectionIdAndResponse

          protected final Map<AbstractFeatures.CollectionResponseKey,AbstractFeatures.ResponseData> collectionIdAndResponse

    - #### collections

          protected List<Map<String,Object>> collections

    - #### iut

          protected URI iut

  - ### Constructor Detail

    - #### AbstractFeatures

          public AbstractFeatures()

  - ### Method Detail

    - #### collectionPaths

          public Iterator<Object[]> collectionPaths(org.testng.ITestContext testContext)

    - #### retrieveRequiredInformationFromTestContext

          public void retrieveRequiredInformationFromTestContext(org.testng.ITestContext testContext)

    - #### validateTypeProperty

          public void validateTypeProperty(AbstractFeatures.CollectionResponseKey collection)

      Abstract Test 22, Test Method 1

           Abstract Test 22: /ats/core/fc-response
           Test Purpose: Validate that the Feature Collections complies with the require structure and contents.
           Requirement: /req/core/fc-response

           Test Method
             1. Validate that the type property is present and has a value of FeatureCollection

      Parameters:
        `collection` - the collection under test, never `null`

    - #### validateFeaturesProperty

          void validateFeaturesProperty(AbstractFeatures.CollectionResponseKey collection)

      Abstract Test 22, Test Method 2

           Abstract Test 22: /ats/core/fc-response
           Test Purpose: Validate that the Feature Collections complies with the require structure and contents.
           Requirement: /req/core/fc-response

           Test Method
             2. Validate the features property is present and that it is populated with an array of feature items.

      Parameters:
        `collection` - the collection under test, never `null`

    - #### validateLinks

          void validateLinks(AbstractFeatures.CollectionResponseKey collection)

      Abstract Test 22, Test Method 4 (Abstract Test 23)

           Abstract Test 22: /ats/core/fc-response
           Test Purpose: Validate that the Feature Collections complies with the require structure and contents.
           Requirement: /req/core/fc-response

           Test Method
             4. If the links property is present, validate that all entries comply with /ats/core/fc-links

           Abstract Test 23: /ats/core/fc-links
           Test Purpose: Validate that the required links are included in the Collections document.
           Requirement: /req/core/fc-links, /req/core/fc-rel-type

           Test Method:
           Verify that the response document includes:
             1. a link to this response document (relation: self),
             2. a link to the response document in every other media type supported by the server (relation: alternate).

           Verify that all links include the rel and type link parameters.

      Parameters:
        `collection` - the collection under test, never `null`

    - #### validateTimeStamp

          public void validateTimeStamp(AbstractFeatures.CollectionResponseKey collection)

      Abstract Test 22, Test Method 5 (Abstract Test 24)

           Abstract Test 22: /ats/core/fc-response
           Test Purpose: Validate that the Feature Collections complies with the require structure and contents.
           Requirement: /req/core/fc-response

           Test Method
             5. If the timeStamp property is present, validate that it complies with /ats/core/fc-timeStamp

           Abstract Test 24: /ats/core/fc-timeStamp
           Test Purpose: Validate the timeStamp parameter returned with a Features response
           Requirement: /req/core/fc-timeStamp

           Test Method: Validate that the timeStamp value is set to the time when the response was generated.

      Parameters:
        `collection` - the collection under test, never `null`

    - #### validateNumberMatched

          void validateNumberMatched(AbstractFeatures.CollectionResponseKey collection)
                              throws URISyntaxException

      Abstract Test 22, Test Method 6 (Abstract Test 25)

           Abstract Test 22: /ats/core/fc-response
           Test Purpose: Validate that the Feature Collections complies with the require structure and contents.
           Requirement: /req/core/fc-response

           Test Method
             6. If the numberMatched property is present, validate that it complies with /ats/core/fc-numberMatched

           Abstract Test 25: /ats/core/fc-numberMatched
           Test Purpose: Validate the numberMatched parameter returned with a Features response
           Requirement: /req/core/fc-numberMatched

           Test Method: Validate that the value of the numberMatched parameter is identical to the number of features in the feature collections that match the selection parameters like bbox, datetime or additional filter parameters.

      Parameters:
        `collection` - the collection under test, never `null`
      Throws:
        `URISyntaxException` - if the creation of a uri fails

    - #### validateNumberReturned

          void validateNumberReturned(AbstractFeatures.CollectionResponseKey collection)

      Abstract Test 22, Test Method 7 (Abstract Test 26)

           Abstract Test 22: /ats/core/fc-response
           Test Purpose: Validate that the Feature Collections complies with the require structure and contents.
           Requirement: /req/core/fc-response

           Test Method
             7. If the numberReturned property is present, validate that it complies with /ats/core/fc-numberReturned

           Abstract Test 26: /ats/core/fc-numberReturned
           Test Purpose: Validate the numberReturned parameter returned with a Features response
           Requirement: /req/core/fc-numberReturned

           Test Method: Validate that the numberReturned value is identical to the number of features in the response.

      Parameters:
        `collection` - the collection under test, never `null`

    - #### validateGeometriesInCrs84

          void validateGeometriesInCrs84(AbstractFeatures.CollectionResponseKey collection)
                                  throws org.locationtech.jts.io.ParseException

      Abstract Test 2, Test Method 1

           Abstract Test 2: /ats/core/crs84
           Test Purpose: Validate that all spatial geometries provided through the API are in the CRS84 spatial reference system unless otherwise requested by the client.
           Requirement: /req/core/crs84

           Test Method
            1. Do not specify a coordinate reference system in any request. All spatial data should be in the CRS84 reference system.
            2. Validate retrieved spatial data using the CRS84 reference system.

      Parameters:
        `collection` - the collection under test, never `null`
      Throws:
        `org.locationtech.jts.io.ParseException` - if the geometry could not be parsed

    - #### isRequired

          protected boolean isRequired(com.reprezen.kaizen.oasparser.model3.Parameter param)

    - #### isExplode

          protected Boolean isExplode(com.reprezen.kaizen.oasparser.model3.Parameter param)

Copyright © 2022 Open Geospatial Consortium. All rights reserved.