ScopedState.h
252 return space_->equalStates(static_cast<const State *>(state_), static_cast<const State *>(other.get()));
void print(std::ostream &out=std::cout) const
Print this state to a stream.
Definition: ScopedState.h:363
const ScopedState operator[](const StateSpacePtr &s) const
Extract a state that corresponds to the components in state space s. Those components will have the s...
Definition: ScopedState.h:542
bool satisfiesBounds() const
Check if the maintained state satisfies bounds.
Definition: ScopedState.h:345
double operator[](const unsigned int index) const
Access the indexth double value this state contains.
Definition: ScopedState.h:279
ScopedState< T > & operator=(const std::vector< double > &reals)
Partial assignment operator. Only sets the double values of the state to specified real values.
Definition: ScopedState.h:220
StateType * operator()() const
Returns a pointer to the contained state (used for Python bindings)
Definition: ScopedState.h:405
double operator[](const std::string &name) const
Access a double value from this state contains using its name.
Definition: ScopedState.h:302
ScopedState< T > & operator=(const double value)
Partial assignment operator. Only sets the double values of the state to a fixed value.
Definition: ScopedState.h:231
double & operator[](const unsigned int index)
Access the indexth double value this state contains.
Definition: ScopedState.h:270
bool operator==(const ScopedState< O > &other) const
Checks equality of two states.
Definition: ScopedState.h:241
ScopedState(StateSpacePtr space)
Given the state space that we are working with, allocate a state.
Definition: ScopedState.h:84
ScopedState(const SpaceInformationPtr &si)
Given the space that we are working with, allocate a state from the corresponding state space.
Definition: ScopedState.h:71
ScopedState(const ScopedState< O > &other)
Copy constructor that allows instantiation from states of other type.
Definition: ScopedState.h:105
double distance(const ScopedState< O > &other) const
Compute the distance to another state.
Definition: ScopedState.h:317
ScopedState< T > & operator=(const ScopedState< O > &other)
Assignment operator that allows conversion of states.
Definition: ScopedState.h:196
const StateType * operator->() const
Returns a pointer to the contained state.
Definition: ScopedState.h:387
bool operator!=(const ScopedState< O > &other) const
Checks equality of two states.
Definition: ScopedState.h:257
ScopedState< T > & operator=(const ScopedState< T > &other)
Assignment operator.
Definition: ScopedState.h:148
double & operator[](const std::string &name)
Access a double value from this state contains using its name.
Definition: ScopedState.h:288
const StateSpacePtr & getSpace() const
Get the state space that the state corresponds to.
Definition: ScopedState.h:142
double distance(const State *state) const
Compute the distance to another state.
Definition: ScopedState.h:325
std::vector< double > reals() const
Return the real values corresponding to this state. If a conversion is not possible,...
Definition: ScopedState.h:353
const StateType & operator*() const
De-references to the contained state.
Definition: ScopedState.h:375
ScopedState(StateSpacePtr space, const State *state)
Given the state space that we are working with, allocate a state and fill that state with a given val...
Definition: ScopedState.h:123
A shared pointer wrapper for ompl::base::SpaceInformation.
A shared pointer wrapper for ompl::base::StateSampler.
A shared pointer wrapper for ompl::base::StateSpace.
AdvancedStateCopyOperation copyStateData(const StateSpacePtr &destS, State *dest, const StateSpacePtr &sourceS, const State *source)
Copy data from source (state from space sourceS) to dest (state from space destS) on a component by c...
Definition: StateSpace.cpp:1236
const ScopedState operator^(const ScopedState< T > &a, const ScopedState< Y > &b)
Given state a from state space A and state b from state space B, construct a state from state space A...
Definition: ScopedState.h:533
const ScopedState< T > & operator>>(const ScopedState< T > &from, ScopedState< Y > &to)
This is a fancy version of the assignment operator. It is a partial assignment, in some sense....
Definition: ScopedState.h:522
std::shared_ptr< ScopedState<> > ScopedStatePtr
Shared pointer to a ScopedState<>
Definition: ScopedState.h:549
std::ostream & operator<<(std::ostream &stream, Cost c)
Output operator for Cost.
Definition: Cost.cpp:39
Main namespace. Contains everything in this library.
Definition: ConstrainedSpaceInformation.h:53