Aikido
aikido::constraint::dart::CollisionFreeOutcome Class Reference

TestableOutcome derivative class intended as (optional) input to isSatisfied method in CollisionFree class. More...

#include <aikido/constraint/dart/CollisionFreeOutcome.hpp>

Inheritance diagram for aikido::constraint::dart::CollisionFreeOutcome:
aikido::constraint::TestableOutcome

Public Member Functions

bool isSatisfied () const override
 Documentation inherited. More...
 
std::string toString () const override
 Returns a string with each pair of CollisionObject names on a separate line. More...
 
void clear ()
 Clears this outcome object. More...
 
std::vector<::dart::collision::Contact > getPairwiseContacts () const
 Return a copy of the vector storing the Contact objects from pairwise collisions. More...
 
std::vector<::dart::collision::Contact > getSelfContacts () const
 Return a copy of the vector storing the Contact objects from self collisions. More...
 
std::string getCollisionObjectName (const ::dart::collision::CollisionObject *object) const
 Gets the name of a CollisionObject. More...
 
- Public Member Functions inherited from aikido::constraint::TestableOutcome
virtual ~TestableOutcome ()=default
 Destructor. More...
 

Protected Attributes

std::vector<::dart::collision::Contact > mPairwiseContacts
 Holds Contact objects from pairwise collisions. More...
 
std::vector<::dart::collision::Contact > mSelfContacts
 Holds Contact objects from self collisions. More...
 

Friends

class CollisionFree
 

Detailed Description

TestableOutcome derivative class intended as (optional) input to isSatisfied method in CollisionFree class.

Member Function Documentation

◆ clear()

void aikido::constraint::dart::CollisionFreeOutcome::clear ( )

Clears this outcome object.

Useful in the event that a CollisionFree object is passed to the isSatisfied() method of more than one constraint object.

◆ getCollisionObjectName()

std::string aikido::constraint::dart::CollisionFreeOutcome::getCollisionObjectName ( const ::dart::collision::CollisionObject *  object) const

Gets the name of a CollisionObject.

The name returned is that of the corresponding BodyNode (if possible). If not, the name of the ShapeFrame is returned instead. This is a helper for toString().

Parameters
[in]objectobject pointer to CollisionObject we want the name of.

◆ getPairwiseContacts()

std::vector<::dart::collision::Contact> aikido::constraint::dart::CollisionFreeOutcome::getPairwiseContacts ( ) const

Return a copy of the vector storing the Contact objects from pairwise collisions.

◆ getSelfContacts()

std::vector<::dart::collision::Contact> aikido::constraint::dart::CollisionFreeOutcome::getSelfContacts ( ) const

Return a copy of the vector storing the Contact objects from self collisions.

◆ isSatisfied()

bool aikido::constraint::dart::CollisionFreeOutcome::isSatisfied ( ) const
overridevirtual

Documentation inherited.

Implements aikido::constraint::TestableOutcome.

◆ toString()

std::string aikido::constraint::dart::CollisionFreeOutcome::toString ( ) const
overridevirtual

Returns a string with each pair of CollisionObject names on a separate line.

Each pair is also marked as being a normal collision or self collision.

Implements aikido::constraint::TestableOutcome.

Friends And Related Function Documentation

◆ CollisionFree

friend class CollisionFree
friend

Member Data Documentation

◆ mPairwiseContacts

std::vector<::dart::collision::Contact> aikido::constraint::dart::CollisionFreeOutcome::mPairwiseContacts
protected

Holds Contact objects from pairwise collisions.

◆ mSelfContacts

std::vector<::dart::collision::Contact> aikido::constraint::dart::CollisionFreeOutcome::mSelfContacts
protected

Holds Contact objects from self collisions.