Aimsun Next Scripting
24.0
|
Public Types | |
enum | GKControlPhaseBeginCoord { eGreen , eYellow , eRed } |
enum | GKControlPhaseRecall { eNo , eMin , eMax , eCoord } |
A phase holds all the signal groups that will be green during a time period.
Usually the user will:
GKControlPhase::GKControlPhase | ( | ) |
bool GKControlPhase::addControlDetector | ( | GKControlDetector * | detec | ) |
Adds a control detector created with GKControlPhase::createControlDetector. The object is not adopted as it can be in other phases.
void GKControlPhase::addSignal | ( | GKControlPlanSignal * | signal, |
GKControlPhaseSignal::FlashingType | flashing = GKControlPhaseSignal::eNo |
||
) |
Adds a signal to this phase indicating if when activated it will flash or it will be a continuous green
GKControlDetector * GKControlPhase::createControlDetector | ( | GKDetector * | netDetector | ) |
Creates a new control detector. The user will set any additional parameter and then add it to this phase using the GKControlPhase::addControlDetector method.
Note that the same control detector can be used in other phases too.
bool GKControlPhase::findSignal | ( | uint | idSignal | ) |
GKControlPhaseBeginCoord GKControlPhase::getBeginCoord | ( | ) |
const QMap< GKDetector *, GKControlDetector * > & GKControlPhase::getControlDetectors | ( | ) |
Returns all the associated detectors in this phase.
GKControlJunction * GKControlPhase::getControlJunction | ( | ) |
float GKControlPhase::getDuration | ( | ) | const |
Gets the phase duration.
float GKControlPhase::getForceOff | ( | ) | const |
float GKControlPhase::getFrom | ( | ) | const |
Gets the start time for this phase, between 0 and the cycle time.
bool GKControlPhase::getHold | ( | ) |
int GKControlPhase::getIdBarrier | ( | ) | const |
int GKControlPhase::getIdRing | ( | ) | const |
bool GKControlPhase::getInterphase | ( | ) | const |
It is this phase as an interphase? (all turns in red)
bool GKControlPhase::getIsDefault | ( | ) | const |
float GKControlPhase::getMaxDuration | ( | ) | const |
Gets the phase maximum duration. Used only in adaptive and external control plans.
float GKControlPhase::getMaximumInitial | ( | ) | const |
float GKControlPhase::getMinDuration | ( | ) | const |
Gets the phase minimum duration. Used only in adaptive and external control plans.
float GKControlPhase::getMinimumGap | ( | ) | const |
float GKControlPhase::getPassageTime | ( | ) | const |
float GKControlPhase::getPermissivePeriodFrom | ( | ) | const |
float GKControlPhase::getPermissivePeriodTo | ( | ) | const |
GKControlPhaseRecall GKControlPhase::getRecall | ( | ) | const |
float GKControlPhase::getRedToGreenYellowTimeDuration | ( | ) | const |
Gets the phase red to green yellow time duration, in seconds. If a -1 is returned it means that the phase will use the red-to-green yellow time defined in the corresponding node control plan.
float GKControlPhase::getSecondsActuation | ( | ) | const |
const QVector< GKControlPhaseSignal > & GKControlPhase::getSignals | ( | ) |
Returns all the signals in this phase. Signals are not in the catalog so you have to use GKNode::getSignal to get the pointer to the GKControlPlanSignal
float GKControlPhase::getTimeBeforeReduce | ( | ) | const |
float GKControlPhase::getTimeToReduce | ( | ) | const |
uint GKControlPhase::getWeakId | ( | ) | const |
float GKControlPhase::getYellowTimeDuration | ( | ) | const |
Gets the phase yellow time duration, from green to red state, in seconds. If a -1 is returned it means that the phase will use the yellow time, from green to red state, defined in the corresponding node control plan.
GKControlPhaseSignal::FlashingType GKControlPhase::isFlashing | ( | int | idSignal | ) | const |
bool GKControlPhase::isUsingGapReduction | ( | ) | const |
returns whether is using gap reduction or not
bool GKControlPhase::isUsingVariableInitial | ( | ) | const |
returns whether is using variable initial or not
bool GKControlPhase::operator< | ( | GKControlPhase & | v | ) | const |
Compares phases using the from time (GKControlPhase::getFrom)
bool GKControlPhase::operator<= | ( | GKControlPhase & | v | ) | const |
Compares phases using the from time (GKControlPhase::getFrom)
bool GKControlPhase::operator> | ( | GKControlPhase & | v | ) | const |
Compares phases using the from time (GKControlPhase::getFrom)
bool GKControlPhase::operator>= | ( | GKControlPhase & | v | ) | const |
Compares phases using the from time (GKControlPhase::getFrom)
void GKControlPhase::removeAllControlDetectors | ( | ) |
Removes all detectors from this phase. Objects are not deleted.
void GKControlPhase::removeAllSignals | ( | ) |
Removes all signals from this phase. The signals are not deleted.
void GKControlPhase::removeControlDetector | ( | const GKControlDetector * | detec | ) |
Removes a detector from this phase. The object is not deleted.
void GKControlPhase::removeSignal | ( | uint | idSignal | ) |
Removes a signal from this phase. The signal is not deleted.
void GKControlPhase::setBeginCoord | ( | const GKControlPhaseBeginCoord | bc | ) |
void GKControlPhase::setControlJunction | ( | GKControlJunction * | junc | ) |
void GKControlPhase::setDuration | ( | const float | d | ) |
Sets the phase duration.
void GKControlPhase::setFlashing | ( | int | idSignal, |
GKControlPhaseSignal::FlashingType | flashing | ||
) |
void GKControlPhase::setForceOff | ( | const float | aForceOff | ) |
void GKControlPhase::setFrom | ( | const float | time | ) |
Sets the start time for this phase, between 0 and the cycle time.
void GKControlPhase::setHold | ( | const bool | h | ) |
void GKControlPhase::setIdBarrier | ( | const int | aIdBarrier | ) |
void GKControlPhase::setIdRing | ( | const int | aIdRing | ) |
void GKControlPhase::setInterphase | ( | const bool | a | ) |
Marks this phase as an interphase (all turns in red)
void GKControlPhase::setIsDefault | ( | const bool | aIsDefault | ) |
void GKControlPhase::setMaxDuration | ( | const float | maxD | ) |
Sets the phase maximum duration. Used only in adaptive and external control plans.
void GKControlPhase::setMaximumInitial | ( | const float | maxI | ) |
void GKControlPhase::setMinDuration | ( | const float | minD | ) |
Sets the phase minimum duration. Used only in adaptive and external control plans.
void GKControlPhase::setMinimumGap | ( | const float | minG | ) |
void GKControlPhase::setPassageTime | ( | const float | passT | ) |
void GKControlPhase::setPermissivePeriodFrom | ( | const float | fperiod | ) |
void GKControlPhase::setPermissivePeriodTo | ( | const float | tperiod | ) |
void GKControlPhase::setRecall | ( | const GKControlPhaseRecall | r | ) |
void GKControlPhase::setRedToGreenYellowTimeDuration | ( | const float | aYellowTimeDuration | ) |
Sets the phase red to green yellow time duration, in seconds. When a -1 is set, the phase will use the red-to-green yellow time defined in the corresponding node control plan.
void GKControlPhase::setSecondsActuation | ( | const float | secA | ) |
void GKControlPhase::setTimeBeforeReduce | ( | const float | timeBR | ) |
void GKControlPhase::setTimeToReduce | ( | const float | timeTR | ) |
void GKControlPhase::setUsingGapReduction | ( | bool | b | ) |
sets using gap reduction option
void GKControlPhase::setUsingVariableInitial | ( | bool | b | ) |
sets using variable initial option
void GKControlPhase::setWeakId | ( | const uint | aid | ) |
void GKControlPhase::setYellowTimeDuration | ( | const float | yellowD | ) |
Sets the phase yellow time duration, from green to red state, in seconds. When a -1 is set, the phase will use the yellow time, from green to red state, defined in the corresponding node control plan.
bool GKControlPhase::turningHasGreen | ( | GKTurning * | turning | ) |
Returns true if this turn movement is allowed in this phase and false otherwise.