Interface AccessGroupProperties

  • All Superinterfaces:
    Cloneable
    All Known Implementing Classes:
    AccessGroupPropertiesImpl

    public interface AccessGroupProperties
    extends Cloneable
    Contains the properties of a mode specific to a link segment type
    Author:
    markr
    • Field Detail

      • DEFAULT_SPEED_EPSILON

        static final double DEFAULT_SPEED_EPSILON
        Epsilon margin when comparing speeds (km/h)
        See Also:
        Constant Field Values
    • Method Detail

      • getMaximumSpeedKmH

        Double getMaximumSpeedKmH()
        Collect the maximum speed in km/h
        Returns:
        the maximum speed in km/h
      • isMaximumSpeedKmHSet

        default boolean isMaximumSpeedKmHSet()
        Verify if a maximum speed is set on this group
        Returns:
        true when set, false otherwise
      • getMaximumSpeedOrDefaultKmH

        default double getMaximumSpeedOrDefaultKmH​(double defaultMaximumSpeed)
        Collect the maximum speed set, or otherwise the provided default
        Parameters:
        defaultMaximumSpeed - to use
        Returns:
        maximum speed
      • setMaximumSpeedKmH

        void setMaximumSpeedKmH​(Double maxSpeedKmH)
        set the maximum speed in km/h
        Parameters:
        maxSpeedKmH - to set
      • getCriticalSpeedKmH

        Double getCriticalSpeedKmH()
        Collect the critical speed in km/h
        Returns:
        the critical speed in km/h
      • isCriticalSpeedKmHSet

        default boolean isCriticalSpeedKmHSet()
        Verify if a critical speed is set on this group
        Returns:
        true when set, false otherwise
      • getCriticalSpeedOrDefaultKmH

        default double getCriticalSpeedOrDefaultKmH​(double defaultCriticalSpeed)
        Collect the critical speed set, or otherwise the provided default
        Parameters:
        defaultCriticalSpeed - to use
        Returns:
        critical speed
      • setCriticalSpeedKmH

        void setCriticalSpeedKmH​(Double criticalSpeedKmH)
        set the critical speed in km/h
        Parameters:
        criticalSpeedKmH - to set
      • getAccessModes

        Set<Mode> getAccessModes()
        The access modes for this group
        Returns:
        access modes
      • removeAccessMode

        boolean removeAccessMode​(Mode toBeRemovedMode)
        Remove access mode
        Parameters:
        toBeRemovedMode - the to be removed mode
        Returns:
        true when success, false otherwise
      • isEqualExceptForModes

        boolean isEqualExceptForModes​(AccessGroupProperties accessProperties)
        Verify if equal to given properties except for the allowed modes
        Parameters:
        accessProperties - to compare against
        Returns:
        true when deemed equal, false otherwise
      • addAccessMode

        void addAccessMode​(Mode mode)
        Add a new access mode to the group
        Parameters:
        mode - to add