Class FeatureImpl

    • Constructor Detail

      • FeatureImpl

        public FeatureImpl​(Collection<Property> properties,
                           AttributeDescriptor desc,
                           FeatureId id)
        Create a Feature with the following content.
        Parameters:
        properties - Collectio of Properties (aka Attributes and/or Associations)
        desc - Nested descriptor
        id - Feature ID
      • FeatureImpl

        public FeatureImpl​(Collection<Property> properties,
                           FeatureType type,
                           FeatureId id)
        Create a Feature with the following content.
        Parameters:
        properties - Collectio of Properties (aka Attributes and/or Associations)
        type - Type of feature to be created
        id - Feature ID
    • Method Detail

      • getIdentifier

        public FeatureId getIdentifier()
        Description copied from interface: Attribute
        Unique Identifier for the attribute.

        This value is non-null in the case that getType().isIdentifiable() is true.

        Specified by:
        getIdentifier in interface Attribute
        Specified by:
        getIdentifier in interface Feature
        Overrides:
        getIdentifier in class AttributeImpl
        Returns:
        A unique identifier for the attribute, or null if the attribute is non-identifiable.
      • getBounds

        public BoundingBox getBounds()
        Get the total bounds of this feature which is calculated by doing a union of the bounds of each geometry this feature is associated with.
        Specified by:
        getBounds in interface Feature
        Returns:
        An Envelope containing the total bounds of this Feature.
        TODO:
        REVISIT: what to return if there are no geometries in the feature? For now we'll return a null envelope, make this part of interface? (IanS - by OGC standards, all Feature must have geom)
      • getDefaultGeometryProperty

        public GeometryAttribute getDefaultGeometryProperty()
        Description copied from interface: Feature
        The default geometric attribute of the feature.

        This method returns null in the case where no such attribute exists.

        Specified by:
        getDefaultGeometryProperty in interface Feature
        Returns:
        The default geometry attribute, or null.
      • setDefaultGeometryProperty

        public void setDefaultGeometryProperty​(GeometryAttribute defaultGeometry)
        Description copied from interface: Feature
        Sets the default geometric attribute of the feature.

        This value must be an attribute which is already defined for the feature. In other words, this method can not be used to add a new attribute to the feature.

        Specified by:
        setDefaultGeometryProperty in interface Feature
        Parameters:
        defaultGeometry - The new geomtric attribute.