Class PlannerDataVertexAnnotated
Defined in File PlannerDataVertexAnnotated.h
Inheritance Relationships
Base Type
public ompl::base::PlannerDataVertex
(Class PlannerDataVertex)
Class Documentation
-
class PlannerDataVertexAnnotated : public ompl::base::PlannerDataVertex
An annotated vertex, adding information about its level in the multilevel hierarchy. Class has two modes: Mode 1 (baseMode), we store a reference to its base state element. In Mode 2 (totalMode), we store a deep copy of the lift of the base state into the total space (NOTE: required for PlannerData functions like decoupleFromPlanner())
Public Functions
-
PlannerDataVertexAnnotated(const ompl::base::State *state)
Constructor for base state. Set mode to baseMode.
-
PlannerDataVertexAnnotated(const PlannerDataVertexAnnotated &rhs)
-
virtual ~PlannerDataVertexAnnotated() override
-
virtual PlannerDataVertex *clone() const override
Return a clone of this object, allocated from the heap.
-
void setLevel(unsigned int level_)
The level of vertex in the bundle space hierarchy.
-
unsigned int getLevel() const
-
void setMaxLevel(unsigned int level_)
The maximum level in the bundle space hierarchy.
-
unsigned int getMaxLevel() const
-
void setComponent(unsigned int component_)
The component of vertex in the graph (start, goal or other component)
-
unsigned int getComponent() const
-
void setTotalState(ompl::base::State *s, ompl::base::SpaceInformationPtr si)
Set total state, i.e. the lift of the base state to the total space (last Spaceinformationptr in sequence). NOTE: Changes mode to totalMode. NOTE: requires Spaceinformationptr (of total space) to free state.
-
virtual const ompl::base::State *getState() const override
Returns base state in baseMode and total state in totalMode. The total space here is the last element of space sequence.
-
ompl::base::State *getStateNonConst() const
Same as getState(), but state can be changed.
-
ompl::base::SpaceInformationPtr getSpaceInformationPtr() const
-
virtual bool operator==(const PlannerDataVertex &rhs) const override
Verifies equality by checking level and base state (mode independent)
Protected Attributes
-
unsigned int level_ = {0}
The level for the base state.
-
unsigned int maxLevel_ = {1}
How many spaces exists in the multilevel structure.
-
unsigned int component_ = {0}
(Optional:) which component in roadmap does vertex belong to
-
bool totalStateIsSet = {false}
There are two modes. Mode 1 is the normal mode where this class contains a reference to the base state. In that case getState() returns the base state. Mode 2 is the total space mode, where we set a total state, in which case getState() returns the total state. Note that we require the class to be in Mode 2 for methods like PlannerData::decoupleFromPlanner(). You can put the class into Mode 2 by calling setTotalState()
-
const ompl::base::State *stateBase_ = {nullptr}
Internal reference to base state. Same as state_ in normal Mode to avoid confusion.
-
ompl::base::SpaceInformationPtr si_ = {nullptr}
Pointer to total space (to free total space element upon deletion)
Friends
-
friend std::ostream &operator<<(std::ostream&, const PlannerDataVertexAnnotated&)
-
PlannerDataVertexAnnotated(const ompl::base::State *state)