Package org.opentrafficsim.core.network
Class LinkDirection
- java.lang.Object
-
- org.opentrafficsim.core.network.LinkDirection
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
DirectedLinkPosition
public class LinkDirection extends Object implements Serializable
Storage for a Link and a GTUDirectionality.Copyright (c) 2013-2022 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
$LastChangedDate: 2015-07-24 02:58:59 +0200 (Fri, 24 Jul 2015) $, @version $Revision: 1147 $, by $Author: averbraeck $, initial version Dec 2, 2015
BSD-style license. See OpenTrafficSim License.- Author:
- Alexander Verbraeck, Peter Knoppers
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description LinkDirection(Link link, GTUDirectionality direction)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
GTUDirectionality
getDirection()
String
getId()
Length
getLength()
Link
getLink()
LinkType
getLinkType()
Node
getNodeFrom()
Node
getNodeTo()
int
hashCode()
String
toString()
-
-
-
Constructor Detail
-
LinkDirection
public LinkDirection(Link link, GTUDirectionality direction)
- Parameters:
link
- Link; the linkdirection
- GTUDirectionality; the direction on the link, with or against the design line
-
-
Method Detail
-
getLink
public final Link getLink()
- Returns:
- link
-
getId
public String getId()
- Returns:
- String; link id
- See Also:
Link.getId()
-
getLinkType
public LinkType getLinkType()
- Returns:
- LinkType; link type
- See Also:
Link.getLinkType()
-
getLength
public Length getLength()
- Returns:
- Length; length
- See Also:
Link.getLength()
-
getDirection
public final GTUDirectionality getDirection()
- Returns:
- direction
-
getNodeTo
public final Node getNodeTo()
- Returns:
- the destination node of the linkdirection
-
getNodeFrom
public final Node getNodeFrom()
- Returns:
- the origin node of the linkdirection
-
-