Class WayConnectionType

    • Field Detail

      • invalid

        private final boolean invalid
        True, if the corresponding primitive is not a way or the way is incomplete
      • linkPrev

        public boolean linkPrev
        True, if linked to the previous member.
      • linkNext

        public boolean linkNext
        True, if linked to the next member.
      • direction

        public WayConnectionType.Direction direction
        direction is FORWARD if the first node of this way is connected to the previous way and / or the last node of this way is connected to the next way. direction is BACKWARD if it is the other way around. direction has a ONEWAY value, if it is tagged as such and it is connected to the previous / next member. ONEWAY_FORWARD == the first node of the oneway is the last node of the previous way ONEWAY_BACKWARD == the last node of the oneway is the last node of the previous way direction has a ROUNDABOUT value, if it is tagged as such and it is somehow connected to the previous / next member. If there is no connection to the previous or next member, then direction has the value NONE.
      • isLoop

        public boolean isLoop
        True, if the element is part of a closed loop of ways.
      • ignoreOneway

        public boolean ignoreOneway
        True, if all oneway features are ignored
      • onewayFollowsPrevious

        public boolean onewayFollowsPrevious
        False, if the way is oneway and it doesn't follow the flow of the previous member
      • onewayFollowsNext

        public boolean onewayFollowsNext
        True, if the way is oneway and it doesn't follow the flow of the next member
    • Constructor Detail

      • WayConnectionType

        public WayConnectionType​(boolean linkPrev,
                                 boolean linkNext,
                                 WayConnectionType.Direction direction)
        Constructs a valid instance.
        Parameters:
        linkPrev - true if linked to the previous member
        linkNext - true if linked to the next member
        direction - the direction type
      • WayConnectionType

        public WayConnectionType​(boolean invalid)
        Constructs a valid or invalid instance.
        Parameters:
        invalid - true if the instance is invalid (i.e does not concern a complete way)
    • Method Detail

      • isValid

        public boolean isValid()
        Determines if the connection type is valid (i.e. it concerns a complete way).
        Returns:
        true if the connection type is valid (i.e. it concerns a complete way)
      • getTooltip

        public String getTooltip()
        Returns the tooltip to display when hovering over the relation member.
        Returns:
        The tooltip, never null.
        Since:
        10248