@AnyLogicInternalAPI public interface TrafficLightDelegate
Modifier and Type | Method and Description |
---|---|
double |
getCurrentPhaseElapsedTime()
Returns time elapsed from beginning of the current phase in model time units or -1 if the
traffic light is off
|
int |
getCurrentPhaseIndex()
Returns 0-based index of the current phase, or -1 if the traffic light is off
|
boolean |
isOn()
Returns
true if the traffic light is on, false otherwise |
void |
switchToNextPhase()
Switches traffic light to next phase.
|
void |
turnOff()
Turns off traffic light
|
void |
turnOn(double offset)
Turns on traffic light with offset in model time units
|
void turnOn(double offset)
offset
- offset in model time unitsvoid turnOff()
boolean isOn()
true
if the traffic light is on, false
otherwisetrue
if the traffic light is on, false
otherwiseint getCurrentPhaseIndex()
double getCurrentPhaseElapsedTime()
void switchToNextPhase()
infinite
duration and
should be switchedCopyright © AnyLogic North America, LLC. All Rights Reserved.