public class HeadwayConflict extends AbstractHeadway
Copyright (c) 2013-2016 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
Headway.ObjectType
Constructor and Description |
---|
HeadwayConflict(ConflictType conflictType,
ConflictRule conflictRule,
String id,
org.djunits.value.vdouble.scalar.Length distance,
org.djunits.value.vdouble.scalar.Length length,
org.djunits.value.vdouble.scalar.Length conflictingLength,
SortedSet<AbstractHeadwayGTU> upstreamConflictingGTUs,
SortedSet<AbstractHeadwayGTU> downstreamConflictingGTUs,
org.djunits.value.vdouble.scalar.Length conflictingVisibility,
org.djunits.value.vdouble.scalar.Speed conflictingSpeedLimit)
Constructor without stop lines.
|
HeadwayConflict(ConflictType conflictType,
ConflictRule conflictRule,
String id,
org.djunits.value.vdouble.scalar.Length distance,
org.djunits.value.vdouble.scalar.Length length,
org.djunits.value.vdouble.scalar.Length conflictingLength,
SortedSet<AbstractHeadwayGTU> upstreamConflictingGTUs,
SortedSet<AbstractHeadwayGTU> downstreamConflictingGTUs,
org.djunits.value.vdouble.scalar.Length conflictingVisibility,
org.djunits.value.vdouble.scalar.Speed conflictingSpeedLimit,
HeadwayStopLine stopLine,
HeadwayStopLine conflictingStopLine)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
org.djunits.value.vdouble.scalar.Length |
getConflictingLength()
Returns the length of the conflict on the conflicting lane.
|
org.djunits.value.vdouble.scalar.Speed |
getConflictingSpeedLimit()
Returns the speed limit on the conflicting lane.
|
HeadwayStopLine |
getConflictingStopLine()
Returns the stop line on the conflicting lane.
|
org.djunits.value.vdouble.scalar.Length |
getConflictingVisibility()
Returns the visibility on the conflicting lane within which conflicting vehicles are visible.
|
ConflictRule |
getConflictRule()
Returns the conflict rule.
|
ConflictType |
getConflictType()
Returns the conflict type.
|
SortedSet<AbstractHeadwayGTU> |
getDownstreamConflictingGTUs()
Returns a set of conflicting GTU's downstream of the start of the conflict ordered close to far from the conflict.
|
HeadwayStopLine |
getStopLine()
Returns the stop line.
|
SortedSet<AbstractHeadwayGTU> |
getUpstreamConflictingGTUs()
Returns a set of conflicting GTU's upstream of the start of the conflict ordered close to far from the conflict.
|
boolean |
isAllStop()
Returns whether this is a all-stop conflict.
|
boolean |
isCrossing()
Returns whether this is a crossing conflict.
|
boolean |
isGiveWay()
Returns whether this is a give-way conflict.
|
boolean |
isMerge()
Returns whether this is a merge conflict.
|
boolean |
isPriority()
Returns whether this is a priority conflict.
|
boolean |
isSplit()
Returns whether this is a split conflict.
|
boolean |
isStop()
Returns whether this is a stop conflict.
|
String |
toString() |
equals, getAcceleration, getDistance, getId, getLength, getObjectType, getOverlap, getOverlapFront, getOverlapRear, getSpeed, hashCode, isAhead, isBehind, isParallel
public HeadwayConflict(ConflictType conflictType, ConflictRule conflictRule, String id, org.djunits.value.vdouble.scalar.Length distance, org.djunits.value.vdouble.scalar.Length length, org.djunits.value.vdouble.scalar.Length conflictingLength, SortedSet<AbstractHeadwayGTU> upstreamConflictingGTUs, SortedSet<AbstractHeadwayGTU> downstreamConflictingGTUs, org.djunits.value.vdouble.scalar.Length conflictingVisibility, org.djunits.value.vdouble.scalar.Speed conflictingSpeedLimit, HeadwayStopLine stopLine, HeadwayStopLine conflictingStopLine) throws org.opentrafficsim.core.gtu.GTUException
conflictType
- conflict typeconflictRule
- conflict ruleid
- iddistance
- distancelength
- length of the conflictconflictingLength
- length of the conflict on the conflicting laneupstreamConflictingGTUs
- conflicting GTU's upstream of the start of the conflictdownstreamConflictingGTUs
- conflicting GTU's downstream of the start of the conflictconflictingVisibility
- visibility on the conflicting lane within which conflicting vehicles are visibleconflictingSpeedLimit
- speed limit on the conflicting lanestopLine
- stop line on the own laneconflictingStopLine
- stop line on the conflicting laneorg.opentrafficsim.core.gtu.GTUException
- when id is null, or parameters are inconsistentpublic HeadwayConflict(ConflictType conflictType, ConflictRule conflictRule, String id, org.djunits.value.vdouble.scalar.Length distance, org.djunits.value.vdouble.scalar.Length length, org.djunits.value.vdouble.scalar.Length conflictingLength, SortedSet<AbstractHeadwayGTU> upstreamConflictingGTUs, SortedSet<AbstractHeadwayGTU> downstreamConflictingGTUs, org.djunits.value.vdouble.scalar.Length conflictingVisibility, org.djunits.value.vdouble.scalar.Speed conflictingSpeedLimit) throws org.opentrafficsim.core.gtu.GTUException
conflictType
- conflict typeconflictRule
- conflict ruleid
- iddistance
- distancelength
- length of the conflictconflictingLength
- length of the conflict on the conflicting laneupstreamConflictingGTUs
- conflicting GTU's upstream of the start of the conflictdownstreamConflictingGTUs
- conflicting GTU's downstream of the start of the conflictconflictingVisibility
- visibility on the conflicting lane within which conflicting vehicles are visibleconflictingSpeedLimit
- speed limit on the conflicting laneorg.opentrafficsim.core.gtu.GTUException
- when id is null, or parameters are inconsistentpublic final ConflictType getConflictType()
public final boolean isCrossing()
public final boolean isMerge()
public final boolean isSplit()
public final ConflictRule getConflictRule()
public final boolean isPriority()
public final boolean isGiveWay()
public final boolean isStop()
public final boolean isAllStop()
public final org.djunits.value.vdouble.scalar.Length getConflictingLength()
public final SortedSet<AbstractHeadwayGTU> getUpstreamConflictingGTUs()
public final SortedSet<AbstractHeadwayGTU> getDownstreamConflictingGTUs()
public final org.djunits.value.vdouble.scalar.Length getConflictingVisibility()
public final org.djunits.value.vdouble.scalar.Speed getConflictingSpeedLimit()
public final HeadwayStopLine getStopLine()
public final HeadwayStopLine getConflictingStopLine()
public final String toString()
toString
in class AbstractHeadway
Copyright © 2014–2016 Delft University of Technology. All rights reserved.