Package com.anylogic.engine.markup
- java.lang.Object
- com.anylogic.engine.markup.AbstractMarkupSubunit<EscalatorGroup>
- com.anylogic.engine.markup.Escalator
- All Implemented Interfaces:
Serializable
public class Escalator extends AbstractMarkupSubunit<EscalatorGroup>
- See Also:
- Serialized Form
Constructor | Description |
---|---|
Escalator() | |
Escalator |
Modifier and Type | Method | Description |
---|---|---|
void | block() |
Blocks the escalator.
|
EscalatorDataSource | getDataSource() | |
EscalatorMovementDirection | getMovementDirection() |
Returns the current movement direction for the escalator.
|
List<? extends Agent> | getPeds() |
Returns the collection of pedestrians currently present on the escalator
|
double | getSpeed() |
Returns the speed of the escalator (in meters per second)
|
double | getSpeed |
Returns the speed of the escalator (in the units passed via the units argument).
|
boolean | isBlocked() |
Checks whether the escalator is blocked, or not.
|
boolean | isRunning() |
Checks whether the escalator is running, or not.
|
void | setBlocked |
Blocks or unblocks the escalator depending on the isBlocked value
|
void | setDataSource | |
void | setMovementDirection |
Sets new movement direction for the escalators.
|
void | setRunning |
Turns the escalator on if the
isRunning value is true; turns the escalator off otherwise. |
void | setSpeed |
Sets the speed of the escalator (in meters per second).
|
void | setSpeed |
Sets the speed of the escalator (in the units passed via the
units argument). |
void | turnOff() |
Turns off the esaclator.
|
void | turnOn() |
Turns the escalator on setting the steps into motion
|
void | unblock() |
Unblocks the escalator allowing pedestrians to enter this escalator
|
public Escalator()
public Escalator(EscalatorMovementDirection movementDirection)
@AnyLogicInternalAPI public EscalatorDataSource getDataSource()
@AnyLogicInternalAPI public void setDataSource(EscalatorDataSource dataSource)
public void turnOn()
Turns the escalator on setting the steps into motion
public void turnOff()
Turns off the esaclator.
When you turn off an escalator, the escalator power supply stops,
so the escalator steps are not moving anymore, but pedestrians can move on their own.
public void setRunning(boolean isRunning)
Turns the escalator on if the
isRunning
value is true; turns the escalator off otherwise.- Parameters:
isRunning
- argument flag
public boolean isRunning()
Checks whether the escalator is running, or not. Returns
true
if the escalator is running.
Returns false
otherwise.- Returns:
- escalator running status
public void block()
Blocks the escalator.
When you block an escalator, the gate before the escalator gets closed,
and pedestrians are no longer allowed to enter this escalator.
public void unblock()
Unblocks the escalator allowing pedestrians to enter this escalator
public void setBlocked(boolean isBlocked)
Blocks or unblocks the escalator depending on the isBlocked value
- Parameters:
isBlocked
- argument flag
public boolean isBlocked()
Checks whether the escalator is blocked, or not. If the escalator is blocked, the function returns
true
,
otherwise it returns false
- Returns:
- escalator blocked status
public EscalatorMovementDirection getMovementDirection()
Returns the current movement direction for the escalator.
The possible return values are:
- EscalatorMovementDirection.UP
- EscalatorMovementDirection.DOWN
- Returns:
- the current movement direction for the escalator
public void setMovementDirection(EscalatorMovementDirection movementDirection)
Sets new movement direction for the escalators.
You set the new value by passing one of the following values as the function argument:
- EscalatorMovementDirection.UP
- EscalatorMovementDirection.DOWN
- Parameters:
movementDirection
- direction
public double getSpeed()
Returns the speed of the escalator (in meters per second)
- Returns:
- the speed of the escalator (in meters per second)
public double getSpeed(SpeedUnits units)
Returns the speed of the escalator (in the units passed via the units argument).
- Parameters:
units
- speed units- Returns:
- the speed of the escalator (in the units passed via the units argument).
public void setSpeed(double speedInMPS)
Sets the speed of the escalator (in meters per second).
- Parameters:
speedInMPS
- speed in meters per second
public void setSpeed(double speed, SpeedUnits units)
Sets the speed of the escalator (in the units passed via the
units
argument).- Parameters:
speed
- escalator speedunits
- speed units
public List<? extends Agent> getPeds()
Returns the collection of pedestrians currently present on the escalator
- Returns:
- list of pedestrians on the escalator