Package com.anylogic.engine.markup
- Constructor Summary
- Method Summary
- Methods inherited from class com.anylogic.engine.markup.AbstractRoadSidePart
- Methods inherited from class com.anylogic.engine.markup.AbstractRoadPart
- Methods inherited from class com.anylogic.engine.markup.AbstractRoadMarkup
- Methods inherited from class com.anylogic.engine.markup.MarkupShape
- Methods inherited from class com.anylogic.engine.markup.AbstractMarkup
- Methods inherited from class java.lang.Object
- Constructor Detail
- Method Detail
- java.lang.Object
- All Implemented Interfaces:
AggregatableAnimationElement
,HasLevel
,SVGElement
,java.io.Serializable
public class BusStop extends AbstractRoadSidePart
Class representing a bus stop located along border of a road segment.
- Author:
- AnyLogic North America, LLC https://anylogic.com
- See Also:
- Serialized Form
BusStop() |
|
BusStop(Road road,
ShapeDrawMode drawMode,
boolean isPublic,
boolean isOnForwardSide,
double offset,
double lengthInMeters) |
Deprecated.
deprecated in version 8.4, will be removed in the future releases
|
Constructor | Description |
---|
java.util.List<Agent> |
getCars() |
Returns ordered list of cars located on this bus stop.
|
double |
getLength() |
Returns length of bus stop along border with lane adjacent to bus stop, measured in pixels.
|
double |
getLength(LengthUnits units) |
Returns length of bus stop measured in the given units along border with lane adjacent to bus stop.
|
int |
nCars() |
Returns number of cars located on this bus stop
|
void |
postInitialize() |
This method is internal and shouldn't be called by user.
it may be removed/renamed in future. |
void |
setDataSource(RoadBasicDataSource dataSource) |
|
void |
setLength(double lengthInPixels) |
Deprecated.
this method is deprecated and may be removed in the next release.
|
void |
setLength(double length,
LengthUnits units) |
Sets length of bus stop measured in the given units along border with lane adjacent to bus stop
|
Modifier and Type | Method | Description |
---|
isOnForwardSide, setOnForwardSide
getOffset, getOffset, getRoad, setOffset, setOffset, setRoad
contains, getLevel, getRoadNetwork, setDebugInfoVisible, setRoadNetwork
error, getDrawMode, getFullName, getOutsideLevelZ, getPresentable, getSpace, initialize, isClickHandled, isPublic, onClick, remove, setDrawMode, setOwner
discardOwner, executeUserAction, findSVGElement, getName, getSVGId, initializeInternal, isVisible, onAggregatorInitialized, onAggregatorVisibilityChanged, removeSVGFromOwner, resetSVGState, setVisible, updateDynamicProperties, updateDynamicPropertiesStructural, updateSVGProperties
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public BusStop()
@Deprecated public BusStop(Road road, ShapeDrawMode drawMode, boolean isPublic, boolean isOnForwardSide, double offset, double lengthInMeters)
Deprecated.
deprecated in version 8.4, will be removed in the future releases
Creates a new road bus stop along the specified side (forward or backward) of the specified road segment at the specified offset.
- Parameters:
road
- Road segment on which the bus stop is created.drawMode
- Where to draw this space markup shape: 2D, 3D or 2D+3D.ispublic
- Iftrue
, the markup shape is visible on container's presentation.isOnForwardSide
- Flag specifying whether the bus stop is created on forward or backward side of road segment.offset
- Offset (measured by guideline of lane adjacent to bus stop) from beginning of road axis to beginning of bus stop, in pixels.lengthInMeters
- Length of bus stop measured in meters along border with lane adjacent to bus stop.
@AnyLogicInternalAPI public void setDataSource(RoadBasicDataSource dataSource)
public int nCars()
Returns number of cars located on this bus stop
- Returns:
- number of cars
public java.util.List<Agent> getCars()
Returns ordered list of cars located on this bus stop.
The first car in the list is the nearest one to the exit point
from bus stop (is the first one to exit the bus stop).
- Returns:
- ordered list of cars
@AnyLogicInternalAPI public void postInitialize()
Description copied from interface:
AggregatableAnimationElement
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.
it may be removed/renamed in future.
public double getLength()
Returns length of bus stop along border with lane adjacent to bus stop, measured in pixels.
- Specified by:
getLength
in classAbstractRoadSidePart
- Returns:
- Length of bus stop in XY-projection, measured in pixels.
public double getLength(LengthUnits units)
Returns length of bus stop measured in the given units along border with lane adjacent to bus stop.
- Returns:
- Length of bus stop in XY-projection, in the given units.
@Deprecated public void setLength(double lengthInPixels)
Deprecated.
this method is deprecated and may be removed in the next release. Please use method with units argument instead.
Sets length of bus stop along border with lane adjacent to bus stop
- Parameters:
lengthInPixels
- of bus stop in XY-projection, measured in pixels
public void setLength(double length, LengthUnits units)
Sets length of bus stop measured in the given units along border with lane adjacent to bus stop
- Parameters:
length
- of bus stop in XY-projectionunits
- length units
-
How can we improve this article?
-