aikido
Public Member Functions | List of all members
aikido::statespace::CompoundStateHandle< _QualifiedState > Class Template Reference

StateHandle for a CartesianProduct. More...

#include <CartesianProduct-impl.hpp>

Inheritance diagram for aikido::statespace::CompoundStateHandle< _QualifiedState >:
aikido::statespace::StateHandle< CartesianProduct, _QualifiedState >

Public Member Functions

 CompoundStateHandle ()
 Construct and initialize to nullptr.
 
 CompoundStateHandle (const StateSpace *_space, State *_state)
 Construct a handle for _state in _space. More...
 
template<class Space = statespace::StateSpace>
Space::State * getSubState (std::size_t _index)
 Gets state by subspace index. More...
 
template<class Space = statespace::StateSpace>
const Space::State * getSubState (std::size_t _index) const
 Gets state by subspace index. More...
 
template<class Space = statespace::StateSpace>
Space::StateHandle getSubStateHandle (std::size_t _index)
 Gets state by subspace index and wraps it in a Space::StateHandle helper class. More...
 
template<class Space = statespace::StateSpace>
Space::StateHandleConst getSubStateHandle (std::size_t _index) const
 Gets state by subspace index and wraps it in a Space::StateHandle helper class. More...
 
- Public Member Functions inherited from aikido::statespace::StateHandle< CartesianProduct, _QualifiedState >
 StateHandle ()
 Constructs a nullptr handle.
 
 StateHandle (const StateSpace *space, QualifiedState *state)
 Wrap state, which must be form the provided StateSpace. More...
 
 StateHandle (const StateHandle &)=default
 
 StateHandle (StateHandle &&)=default
 
StateHandleoperator= (StateHandle &&)=default
 
StateHandleoperator= (const StateHandle &)=default
 
 operator QualifiedState * () const
 Implicitly convert to a State pointer.
 
void reset ()
 Resets StateHandle to nullptr.
 
void reset (const StateSpace *space, QualifiedState *state)
 Resets the state, which must be from the provided StateSpace. More...
 
auto getState () -> typename std::enable_if<!std::is_const< Q >::value, Q * >::type
 Returns the State. More...
 
auto getState () const -> typename std::conditional< std::is_const< Q >::value, Q *, const Q * >::type
 Returns the State. More...
 
const StateSpacegetStateSpace () const
 Returns the state space that created this state. More...
 

Additional Inherited Members

- Public Types inherited from aikido::statespace::StateHandle< CartesianProduct, _QualifiedState >
using StateSpace = CartesianProduct
 
using QualifiedState = _QualifiedState
 
using State = typename StateSpace::State
 
using ConstState = typename std::conditional< std::is_const< QualifiedState >::value, QualifiedState, const QualifiedState >::type
 
- Protected Attributes inherited from aikido::statespace::StateHandle< CartesianProduct, _QualifiedState >
const StateSpacemSpace
 State space of the sate that is managed by this handler.
 
QualifiedState * mState
 State managed by this handler. This can be either const or non-const type.
 

Detailed Description

template<class _QualifiedState>
class aikido::statespace::CompoundStateHandle< _QualifiedState >

StateHandle for a CartesianProduct.

The template parameter is necessary to support both const and non-const states.

Constructor & Destructor Documentation

§ CompoundStateHandle()

template<class _QualifiedState >
aikido::statespace::CompoundStateHandle< _QualifiedState >::CompoundStateHandle ( const StateSpace _space,
State *  _state 
)
inline

Construct a handle for _state in _space.

Parameters
_spacestate space that created _state
_statestate created by _space

Member Function Documentation

§ getSubState() [1/2]

template<class _QualifiedState >
template<class Space = statespace::StateSpace>
Space::State* aikido::statespace::CompoundStateHandle< _QualifiedState >::getSubState ( std::size_t  _index)
inline

Gets state by subspace index.

Template Parameters
Spacetype of StateSpace for subspace _index
Parameters
_indexin the range [ 0, getNumSubspaces() ]
Returns
state at _index

§ getSubState() [2/2]

template<class _QualifiedState >
template<class Space = statespace::StateSpace>
const Space::State* aikido::statespace::CompoundStateHandle< _QualifiedState >::getSubState ( std::size_t  _index) const
inline

Gets state by subspace index.

Template Parameters
Spacetype of StateSpace for subspace _index
Parameters
_indexin the range [ 0, getNumSubspaces() ]
Returns
state at _index

§ getSubStateHandle() [1/2]

template<class _QualifiedState >
template<class Space = statespace::StateSpace>
Space::StateHandle aikido::statespace::CompoundStateHandle< _QualifiedState >::getSubStateHandle ( std::size_t  _index)
inline

Gets state by subspace index and wraps it in a Space::StateHandle helper class.

Template Parameters
Spacetype of StateSpace for subspace _index
Parameters
_indexin the range [ 0, getNumSubspaces() ]
Returns
state at _index

§ getSubStateHandle() [2/2]

template<class _QualifiedState >
template<class Space = statespace::StateSpace>
Space::StateHandleConst aikido::statespace::CompoundStateHandle< _QualifiedState >::getSubStateHandle ( std::size_t  _index) const
inline

Gets state by subspace index and wraps it in a Space::StateHandle helper class.

Template Parameters
Spacetype of StateSpace for subspace _index
Parameters
_indexin the range [ 0, getNumSubspaces() ]
Returns
state at _index

The documentation for this class was generated from the following files: