hpp::core::ConstraintSet Class Reference

Set of constraints applicable to a robot configuration. More...

#include <hpp/core/constraint-set.hh>

Inheritance diagram for hpp::core::ConstraintSet:
Collaboration diagram for hpp::core::ConstraintSet:

Public Member Functions

void addConstraint (const ConstraintPtr_t &constraint)
 Add a constraint to the set. More...
 
const ConfigProjectorPtr_tconfigProjector () const
 Return pointer to config projector if any. More...
 
bool isSatisfied (ConfigurationIn_t config)
 Check whether a configuration statisfies the constraint. More...
 
- Public Member Functions inherited from hpp::core::Constraint
bool apply (ConfigurationOut_t configuration)
 Function that applies the constraint. More...
 
const std::string & name () const
 Get name of constraint. More...
 

Static Public Member Functions

static ConstraintSetPtr_t create (const DevicePtr_t &robot, const std::string &name)
 Return shared pointer to new object. More...
 

Protected Types

typedef std::deque< ConstraintPtr_tConstraints_t
 

Protected Member Functions

 ConstraintSet (const DevicePtr_t &robot, const std::string &name)
 
void init (const ConstraintSetPtr_t &self)
 Store weak pointer to itself. More...
 
virtual bool impl_compute (ConfigurationOut_t configuration)
 User defined implementation of the constraint. More...
 
- Protected Member Functions inherited from hpp::core::Constraint
 Constraint (const std::string &name)
 Constructor. More...
 
void init (const ConstraintPtr_t &self)
 Store shared pointer to itself. More...
 

Detailed Description

Set of constraints applicable to a robot configuration.

Warning
If the set is to contain a ConfigProjector and several LockedJoint instances, the configProjector should be inserted first since following numerical projections might affect locked degrees of freedom.

Member Typedef Documentation

◆ Constraints_t

Constructor & Destructor Documentation

◆ ConstraintSet()

hpp::core::ConstraintSet::ConstraintSet ( const DevicePtr_t robot,
const std::string &  name 
)
protected

Member Function Documentation

◆ addConstraint()

void hpp::core::ConstraintSet::addConstraint ( const ConstraintPtr_t constraint)
inline

Add a constraint to the set.

◆ configProjector()

const ConfigProjectorPtr_t& hpp::core::ConstraintSet::configProjector ( ) const
inline

Return pointer to config projector if any.

◆ create()

static ConstraintSetPtr_t hpp::core::ConstraintSet::create ( const DevicePtr_t robot,
const std::string &  name 
)
inlinestatic

Return shared pointer to new object.

References init().

◆ impl_compute()

virtual bool hpp::core::ConstraintSet::impl_compute ( ConfigurationOut_t  configuration)
protectedvirtual

User defined implementation of the constraint.

Implements hpp::core::Constraint.

◆ init()

void hpp::core::ConstraintSet::init ( const ConstraintSetPtr_t self)
inlineprotected

Store weak pointer to itself.

References hpp::core::Constraint::init().

Referenced by create().

◆ isSatisfied()

bool hpp::core::ConstraintSet::isSatisfied ( ConfigurationIn_t  config)
virtual

Check whether a configuration statisfies the constraint.

Implements hpp::core::Constraint.