AnyLogic AnyLogic
Expand
Font size
All Implemented Interfaces:
java.io.Serializable

public class Escalator
extends AbstractMarkupSubunit<EscalatorGroup>
See Also:
Serialized Form

Constructor Summary

Constructors 
Escalator()  
Escalator​(EscalatorMovementDirection movementDirection)  
Constructor Description

Method Summary

All Methods Instance Methods Concrete Methods 
void block()
Blocks the escalator.
EscalatorDataSource getDataSource()  
EscalatorMovementDirection getMovementDirection()
Returns the current movement direction for the escalator.
java.util.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​(SpeedUnits units)
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​(boolean isBlocked)
Blocks or unblocks the escalator depending on the isBlocked value
void setDataSource​(EscalatorDataSource dataSource)  
void setMovementDirection​(EscalatorMovementDirection movementDirection)
Sets new movement direction for the escalators.
void setRunning​(boolean isRunning)
Turns the escalator on if the isRunning value is true; turns the escalator off otherwise.
void setSpeed​(double speedInMPS)
Sets the speed of the escalator (in meters per second).
void setSpeed​(double speed, SpeedUnits units)
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
Modifier and Type Method Description

Methods inherited from class com.anylogic.engine.markup.AbstractMarkupSubunit

getName, getOwner

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

Escalator

public Escalator()

Escalator

public Escalator​(EscalatorMovementDirection movementDirection)

Method Detail

getDataSource

@AnyLogicInternalAPI
public EscalatorDataSource getDataSource()

setDataSource

@AnyLogicInternalAPI
public void setDataSource​(EscalatorDataSource dataSource)

turnOn

public void turnOn()
Turns the escalator on setting the steps into motion

turnOff

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.

setRunning

public void setRunning​(boolean isRunning)
Turns the escalator on if the isRunning value is true; turns the escalator off otherwise.
Parameters:
isRunning - argument flag

isRunning

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

block

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.

unblock

public void unblock()
Unblocks the escalator allowing pedestrians to enter this escalator

setBlocked

public void setBlocked​(boolean isBlocked)
Blocks or unblocks the escalator depending on the isBlocked value
Parameters:
isBlocked - argument flag

isBlocked

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

getMovementDirection

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

setMovementDirection

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

getSpeed

public double getSpeed()
Returns the speed of the escalator (in meters per second)
Returns:
the speed of the escalator (in meters per second)

getSpeed

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).

setSpeed

public void setSpeed​(double speedInMPS)
Sets the speed of the escalator (in meters per second).
Parameters:
speedInMPS - speed in meters per second

setSpeed

public void setSpeed​(double speed,
                     SpeedUnits units)
Sets the speed of the escalator (in the units passed via the units argument).
Parameters:
speed - escalator speed
units - speed units

getPeds

public java.util.List<? extends Agent> getPeds()
Returns the collection of pedestrians currently present on the escalator
Returns:
list of pedestrians on the escalator
How can we improve this article?