Interface Zone

    • Field Detail

      • LOGGER

        static final Logger LOGGER
        the logger
      • ZONE_ID_CLASS

        static final Class<Zone> ZONE_ID_CLASS
        the class to use for the id generation
    • Method Detail

      • addInputProperty

        void addInputProperty​(String key,
                              Object value)
        Add a property from the original input that is not part of the readily available members
        Parameters:
        key - key (name) of the input property
        value - value of the input property
      • getInputProperty

        Object getInputProperty​(String key)
        collect a property
        Parameters:
        key - for the property
        Returns:
        property itself
      • getCentroid

        Centroid getCentroid()
        Returns the centroid of this zone
        Returns:
        centroid of this zone
      • setGeometry

        void setGeometry​(org.locationtech.jts.geom.Geometry geometry)
        set the geometry (outer border) of this zone, can be a polygon, but also a line string
        Parameters:
        geometry - of the zone
      • getGeometry

        org.locationtech.jts.geom.Geometry getGeometry()
        Collect the geometry (outer border) of this zone
        Returns:
        geometry of the zone
      • setName

        void setName​(String name)
        Name of the zone
        Parameters:
        name - of the zone
      • getName

        String getName()
        Name of the zone
        Returns:
        name of the zone
      • clone

        Zone clone()
        Create a shallow copy of this entity
        Specified by:
        clone in interface IdAble
        Returns:
        shallow copy of entity
      • getIdClass

        default Class<Zone> getIdClass()
        Each managed id class is expected to generate its ids based on its class signature. To be able to generate the correct id the class used for id generation is to be provided via this method call.
        Specified by:
        getIdClass in interface ManagedId
        Returns:
        idClass to use for generating ids for instances of this idable derived class
      • hasGeometry

        default boolean hasGeometry()
        verify if the zone has a geometry
        Returns:
        true if available, false otherwise
      • hasCentroid

        default boolean hasCentroid()
        verify if centroid is present
        Returns:
        true when present, false otherwise
      • hasName

        default boolean hasName()
        Verify if a name has been set
        Returns:
        true when present, false otherwise
      • hasInputProperty

        default boolean hasInputProperty​(String key)
        Verify if input property exists
        Parameters:
        key - to check
        Returns:
        truw when present, false otherwise
      • getEnvelope

        default org.locationtech.jts.geom.Envelope getEnvelope()
        collect the envelope (bounding box) of this zone's geometry. In case, the zone has no geometry we revert to using the geometry (location) of its centroid.
        Returns:
        envelope of the zone