44 namespace ompl
58 ~GoalStates() override;
62 unsigned int maxSampleCount() const override;
66 void print(std::ostream &out = std::cout) const override;
75 virtual void clear();
78 virtual bool hasStates() const;
84 virtual std::size_t getStateCount() const;
Abstract definition of a goal region that can be sampled.
double distanceGoal(const State *st) const override
Compute the distance to the goal (heuristic). This function is the one used in computing the distance...
virtual bool hasStates() const
Check if there are any states in this goal region.
unsigned int maxSampleCount() const override
Return the maximum number of samples that can be asked for before repeating.
std::vector< State * > states_
The goal states. Only ones that are valid are considered by the motion planner.
virtual std::size_t getStateCount() const
Return the number of valid goal states.
virtual void addState(const State *st)
Add a goal state.
void sampleGoal(State *st) const override
Sample a state in the goal region.
void print(std::ostream &out=std::cout) const override
Print information about the goal data structure to a stream.
virtual void clear()
Clear all goal states.
GoalStates(const SpaceInformationPtr &si)
Create a goal representation that is in fact a set of states
virtual const State * getState(unsigned int index) const
Return a pointer to the indexth state in the state list.
A shared pointer wrapper for ompl::base::SpaceInformation.
This bit is set if casting to goal states (ompl::base::GoalStates) is possible.