AURobotServers
4
|
#include <uobstaclehist.h>
Public Member Functions | |
void | clear () |
UObstacleGroup * | getGroup (int idx) |
UObstacleGroup * | getGroup (unsigned long serial, bool mayCreate) |
UObstacleGroup * | getGroupFixed () |
int | getGroupNewest () |
UObstacleGroup * | getGroupNewest (int cnt) |
int | getGroupsCnt () |
int | getGroupsMax () |
UObstacleHist () | |
virtual | ~UObstacleHist () |
Public Attributes | |
ULock | ogLock |
Static Public Attributes | |
static const int | MAX_OBST_GRPS = 100 |
Protected Attributes | |
UObstacleGroup | fixeds |
UObstacleGroup | groups [MAX_OBST_GRPS] |
int | groupsCnt |
int | groupsNewest |
UTime | updTime |
Holds the most recent obstacle history Initially for reactive behaviour only.
UObstacleHist::UObstacleHist | ( | ) |
Constructor
References groupsCnt, and groupsNewest.
|
virtual |
Destructor
|
inline |
|
inline |
get number of obstacle groups
References groups.
Referenced by getGroupFixed(), and UResLaserIfObst::handleObstGrp().
UObstacleGroup * UObstacleHist::getGroup | ( | unsigned long | serial, |
bool | mayCreate | ||
) |
get obstacle groups with this serial number
References UObstacleGroup::clear(), fixeds, getGroupsMax(), UObstacleGroup::getSerial(), groups, groupsCnt, groupsNewest, UObstacleGroup::setSerial(), ULock::tryLock(), and ULock::unlock().
|
inline |
Get pointer to the obstacle group with the fixed obstacles
References fixeds, getGroup(), and getGroupNewest().
Referenced by UNavPaint::paint().
|
inline |
get index of newest obstacle group
References groupsNewest.
Referenced by getGroupFixed(), UResLaserIfObst::methodCall(), and UNavPaint::paint().
UObstacleGroup * UObstacleHist::getGroupNewest | ( | int | cnt | ) |
get obstacle group from newest and back with this count
References groups, groupsCnt, and groupsNewest.
|
inline |
get number of obstacle groups
References groupsCnt.
Referenced by UFunctionLaserIfData::handleLaserIf(), UFunctionLaserIfData::handleLaserObst(), UResLaserIfObst::methodCall(), and UNavPaint::paint().
|
inline |
|
protected |
Obstacle group for fixed obstacles.
Referenced by getGroup(), getGroupFixed(), UResLaserIfObst::handleObstGrp(), UResLaserIfObst::listGroup(), UResLaserIfObst::listGroups(), and UResLaserIfObst::methodCall().
|
protected |
array of pointert to the newest obstacle groups.
Referenced by getGroup(), getGroupNewest(), UResLaserIfObst::listGroup(), UResLaserIfObst::listGroups(), and UResLaserIfObst::methodCall().
|
protected |
Number of used groups
Referenced by clear(), getGroup(), getGroupNewest(), getGroupsCnt(), UResLaserIfObst::handleObst(), UResLaserIfObst::listGroup(), UResLaserIfObst::listGroups(), UResLaserIfObst::snprint(), and UObstacleHist().
|
protected |
Newest group
Referenced by getGroup(), getGroupNewest(), UResLaserIfObst::listGroup(), UResLaserIfObst::listGroups(), and UObstacleHist().
|
static |
max number of obstacle groups that can be stored in this class
Referenced by getGroupsMax(), UResLaserIfObst::listGroup(), UResLaserIfObst::listGroups(), and UResLaserIfObst::methodCall().
ULock UObstacleHist::ogLock |
Lock to ensure integrity in obstacle history
Referenced by UResLaserIfObst::handleObst(), UResLaserIfObst::methodCall(), and UNavPaint::paint().
|
protected |
Updated with this timestamp
Referenced by UResLaserIfObst::handleObst(), and UResLaserIfObst::snprint().