#include <SoccerTypes.h>
Public Methods | |
Time (int iTime=-1, int iStopped=0) | |
bool | updateTime (int iTime) |
bool | setTimeStopped (int iTime) |
int | getTime () |
int | getTimeStopped () |
int | getTimeDifference (Time t) |
bool | isStopped () |
Time | getTimeAddedWith (int iCycles) |
bool | addToTime (int iCycles) |
void | show (ostream &os=cout) |
Time | operator+ (const int &i) |
Time | operator+ (Time t) |
Time | operator- (const int &i) |
int | operator- (Time t) |
void | operator= (const int &i) |
void | operator+= (Time t) |
void | operator+= (const int &i) |
void | operator-= (Time t) |
void | operator-= (const int &i) |
bool | operator!= (Time t) |
bool | operator!= (const int &i) |
bool | operator== (Time t) |
bool | operator== (const int &i) |
bool | operator< (Time t) |
bool | operator< (const int &i) |
bool | operator<= (Time t) |
bool | operator<= (const int &i) |
bool | operator> (Time t) |
bool | operator> (const int &i) |
bool | operator>= (Time t) |
bool | operator>= (const int &i) |
Private Attributes | |
int | m_iTime |
int | m_iStopped |
Friends | |
ostream & | operator<< (ostream &os, Time t) |
Definition at line 523 of file SoccerTypes.h.
|
This is the constructor for the Time class, it receives two arguments. The actual time and how long the time has stopped.
Definition at line 75 of file SoccerTypes.cpp. References m_iStopped, and m_iTime. Referenced by getTimeAddedWith(), operator!=(), operator+(), and operator<(). |
|
This method adds 'iCycles' to the current time. The current values are updated. The method getTimeAddedWith is used to calculated the new time.
Definition at line 195 of file SoccerTypes.cpp. References getTimeAddedWith(). Referenced by operator+=(), and operator-=(). |
|
This method returns the actual time, that is the number of cycles that have passed.
Definition at line 112 of file SoccerTypes.cpp. References m_iTime. Referenced by SenseHandler::analyzeFullStateMessage(), SenseHandler::analyzeSeeMessage(), SenseHandler::analyzeSenseMessage(), Object::getConfidence(), WorldModel::getCurrentCycle(), getTimeAddedWith(), getTimeDifference(), WorldModel::getTimeSinceLastCatch(), BasicCoach::mainLoopNormal(), WorldModel::mapUnknownPlayers(), operator+(), operator+=(), operator-=(), operator<<(), WorldModel::predictNrCyclesToPoint(), WorldModel::processPerfectHearInfoBall(), WorldModel::processPlayerMessage(), WorldModel::removeGhosts(), BasicPlayer::searchBall(), WorldModel::show(), show(), WorldModel::updateAfterSeeMessage(), and WorldModel::updateAgentAndBallAfterSense(). |
|
This method returns a new time class denoting the time when 'iCycles' are added to the current time. There are different situations possible. When the added time is positive and the time stands still, the cycles are added to the stopped time, otherwise they are added to the actual time. When the added time is negative and the time stands still, the cycles are subtracted from the stopped time. Otherwise the time is subtracted from the actual time.
Definition at line 161 of file SoccerTypes.cpp. References getTime(), getTimeStopped(), and Time(). |
|
This method returns the time difference between two time objects.
Definition at line 128 of file SoccerTypes.cpp. References getTime(), and getTimeStopped(). Referenced by SenseHandler::analyzeSeeMessage(), SenseHandler::analyzeSenseMessage(), Object::getConfidence(), operator!=(), operator-(), and operator<(). |
|
This method returns the time the time has stopped, that is the number of cycles the time stood on the current value.
Definition at line 120 of file SoccerTypes.cpp. References m_iStopped. Referenced by SenseHandler::analyzeSenseMessage(), getTimeAddedWith(), getTimeDifference(), WorldModel::mapUnknownPlayers(), operator+(), operator+=(), operator<<(), and show(). |
|
This method returns a boolean value indicating whether the time currently is stopped.
Definition at line 142 of file SoccerTypes.cpp. References m_iStopped. Referenced by WorldModel::drawCoordinationGraph(), and WorldModel::isTimeStopped(). |
|
This method returns a boolean indicating whether the current time is inequal to the time specified by the integer 'i'. 'i' is first converted to the time object (i,0). When the time difference returned by getTimeDifference between these two time objects is inequal to zero true is returned, false otherwise
Definition at line 307 of file SoccerTypes.cpp. References getTimeDifference(), and Time(). |
|
This method returns a boolean indicating whether the current time is inequal to the time t. When the time difference returned by getTimeDifference between these two time objects is inequal to zero true is returned, false otherwise.
Definition at line 319 of file SoccerTypes.cpp. References getTimeDifference(). |
|
This method returns the result of adding time 't' to the current time. No changes are made to the current object. It is defined by (t1,s1) + (t2,s2) = (t1+t2,s2). The stopped time of the first time tuple is neglected, since this has already been passed.
Definition at line 226 of file SoccerTypes.cpp. References getTime(), getTimeStopped(), and Time(). |
|
This method returns the time as if 'i' cycles would be added to the current time. The method getTimeAddedWith is used for this. No changes are made to the current object.
Definition at line 215 of file SoccerTypes.cpp. References getTimeAddedWith(). |
|
This method updates the time by adding 'i' cycles to the current time. The method addToTime is used for this.
Definition at line 263 of file SoccerTypes.cpp. References addToTime(). |
|
This method updates the time by adding the time 't' to the current time. It is defined by (t1,s1) + (t2,s2) = (t1+t2,s2). The stopped time of the first time tuple is neglected, since this has already been passed.
Definition at line 273 of file SoccerTypes.cpp. References getTime(), getTimeStopped(), setTimeStopped(), and updateTime(). |
|
This method returns the result the difference between the two times and is equal to the method getTimeDifference.
Definition at line 245 of file SoccerTypes.cpp. References getTimeDifference(). |
|
This method returns the time as if 'i' cycles would be subtracted from the current time. The method getTimeAddedWith is used for this. No changes are made to the current object.
Definition at line 236 of file SoccerTypes.cpp. References getTimeAddedWith(). |
|
This method updates the time by subtractign 'i' cycles from the current time. The method addToTime is used for this with '-i' as its argument.
Definition at line 283 of file SoccerTypes.cpp. References addToTime(). |
|
This method updates the time by subtracting time 't' from the current time. It is defined by (t1,s1) + (t2,s2) = (t1-t2,0). The stopped time is set to zero.
Definition at line 292 of file SoccerTypes.cpp. References getTime(), setTimeStopped(), and updateTime(). |
|
This method returns a boolean indicating whether the current time is smaller than the time denoted by the integer 'i'. Herefore first a time object (i,0) is created.
Definition at line 365 of file SoccerTypes.cpp. References Time(). |
|
This method returns a boolean indicating whether the current time is smaller than the time t. When the time difference returned by getTimeDifference is smaller than zero, true is returned, false otherwise
Definition at line 354 of file SoccerTypes.cpp. References getTimeDifference(). |
|
This method returns a boolean indicating whether the current time is smaller than or equal to the time denoted by the integer 'i'. Herefore first a time object (i,0) is created.
Definition at line 388 of file SoccerTypes.cpp. |
|
This method returns a boolean indicating whether the current time is smaller than or equal to the time t.
Definition at line 376 of file SoccerTypes.cpp. |
|
This method returns a new time object (i,0). The argument 'i' is thus denoted as the actual time.
Definition at line 254 of file SoccerTypes.cpp. References setTimeStopped(), and updateTime(). |
|
This method returns a boolean indicating whether the current time equals the time as specified by the integer 'i'. 'i' is first converted to the time object (i,0). When the time difference returned by getTimeDifference between these two time objects equals zero, true is returned, false otherwise
Definition at line 332 of file SoccerTypes.cpp. |
|
This method returns a boolean indicating whether the current time equals the time t. When the time difference returned by getTimeDifference between these two time objects equals zero, true is returned, false otherwise
Definition at line 342 of file SoccerTypes.cpp. |
|
This method returns a boolean indicating whether the current time is larger than the time denoted by the integer 'i'. Herefore first a time object (i,0) is created.
Definition at line 410 of file SoccerTypes.cpp. |
|
This method returns a boolean indicating whether the current time is larger than the time t, that is it is not smaller than or equal to 't'.
Definition at line 397 of file SoccerTypes.cpp. |
|
This method returns a boolean indicating whether the current time is larger than or equal to the time denoted by the integer 'i'. Herefore first a time object (i,0) is created.
Definition at line 431 of file SoccerTypes.cpp. |
|
This method returns a boolean indicating whether the current time is larger than or equal to than the time t, that is it is not smaller than 't'.
Definition at line 419 of file SoccerTypes.cpp. |
|
This methods sets the stopped time, which denotes the number of cycles time stood still.
Definition at line 103 of file SoccerTypes.cpp. References m_iStopped. Referenced by operator+=(), operator-=(), and operator=(). |
|
This method prints the time to the specified output stream. Time is printed as the two tuple (t,s) where t denotes the actual time and s the number of stopped cycles.
Definition at line 205 of file SoccerTypes.cpp. References getTime(), and getTimeStopped(). |
|
This method updates the time to 'iTime'. When the actual time was already 'iTime' the current time is kept unchanged and the time stopped is raised with one. Otherwise the actual time is changed to 'iTime' and the stopped time is set to 0.
Definition at line 87 of file SoccerTypes.cpp. References m_iStopped, and m_iTime. Referenced by SenseHandler::analyzeFullStateMessage(), SenseHandler::analyzeSeeGlobalMessage(), SenseHandler::analyzeSenseMessage(), BasicPlayer::getInterceptionPointBall(), operator+=(), operator-=(), operator=(), and WorldModel::updateAgentAndBallAfterSense(). |
|
Overloaded version of the C++ output operator for a Time class. This operator makes it possible to use Time objects in output statements (e.g. cout << t). The current cycle and the stopped time are printed in the format (t1,t2).
Definition at line 443 of file SoccerTypes.cpp. |
|
Number of cycles stopped at m_iTime Definition at line 526 of file SoccerTypes.h. Referenced by getTimeStopped(), isStopped(), setTimeStopped(), Time(), and updateTime(). |
|
Number of cycles, denoting the time Definition at line 525 of file SoccerTypes.h. Referenced by getTime(), Time(), and updateTime(). |