Drake
Drake C++ Documentation
CollisionCheckerContext Class Reference

Detailed Description

This class represents the data necessary for CollisionChecker to operate safely across multiple threads in its const API.

Instances of this class are owned and managed by a particular CollisionChecker.

If using OMP to perform parallel const queries on a CollisionChecker, it will never be necessary to interact with CollisionCheckerContext instances. Only if using some other threading paradigm will it be necessary to work with "stand alone" instances. See CollisionChecker's documentation for more details.

In all cases, modifying context should happen through CollisionChecker::PerformOperationAgainstAllModelContexts(). Modifying the contained Drake Contexts directly is generally erroneous.

#include <drake/planning/collision_checker_context.h>

Public Member Functions

 CollisionCheckerContext (const RobotDiagram< double > *model)
 The resulting object stores an alias to model; the passed model should have a lifetime greater than the constructed object. More...
 
virtual ~CollisionCheckerContext ()
 
std::unique_ptr< CollisionCheckerContextClone () const
 
const systems::Context< double > & model_context () const
 Gets the contained model context. More...
 
const systems::Context< double > & plant_context () const
 Gets the contained plant context. More...
 
const systems::Context< double > & scene_graph_context () const
 Gets the contained scene graph context. More...
 
const geometry::QueryObject< double > & GetQueryObject () const
 Gets the scene graph geometry query object. More...
 
systems::Context< double > & mutable_model_context ()
 
systems::Context< double > & mutable_plant_context ()
 
systems::Context< double > & mutable_scene_graph_context ()
 
Does not allow copy, move, or assignment generally.

Protected copy construction is enabled for sub-classes to use in their implementation of DoClone().

CollisionCheckerContextoperator= (const CollisionCheckerContext &)=delete
 
 CollisionCheckerContext (CollisionCheckerContext &&)=delete
 
CollisionCheckerContextoperator= (CollisionCheckerContext &&)=delete
 

Protected Member Functions

 CollisionCheckerContext (const CollisionCheckerContext &other)
 Derived classes can use this copy constructor to help implement their own DoClone() methods. More...
 
virtual std::unique_ptr< CollisionCheckerContextDoClone () const
 Allow derived context types to implement additional clone behavior. More...
 

Constructor & Destructor Documentation

◆ CollisionCheckerContext() [1/3]

◆ CollisionCheckerContext() [2/3]

CollisionCheckerContext ( const RobotDiagram< double > *  model)
explicit

The resulting object stores an alias to model; the passed model should have a lifetime greater than the constructed object.

Precondition
model is not null.

◆ ~CollisionCheckerContext()

virtual ~CollisionCheckerContext ( )
virtual

◆ CollisionCheckerContext() [3/3]

CollisionCheckerContext ( const CollisionCheckerContext other)
protected

Derived classes can use this copy constructor to help implement their own DoClone() methods.

Member Function Documentation

◆ Clone()

std::unique_ptr<CollisionCheckerContext> Clone ( ) const

◆ DoClone()

virtual std::unique_ptr<CollisionCheckerContext> DoClone ( ) const
protectedvirtual

Allow derived context types to implement additional clone behavior.

◆ GetQueryObject()

const geometry::QueryObject<double>& GetQueryObject ( ) const

Gets the scene graph geometry query object.

◆ model_context()

const systems::Context<double>& model_context ( ) const

Gets the contained model context.

◆ mutable_model_context()

systems::Context<double>& mutable_model_context ( )

◆ mutable_plant_context()

systems::Context<double>& mutable_plant_context ( )

◆ mutable_scene_graph_context()

systems::Context<double>& mutable_scene_graph_context ( )

◆ operator=() [1/2]

CollisionCheckerContext& operator= ( const CollisionCheckerContext )
delete

◆ operator=() [2/2]

◆ plant_context()

const systems::Context<double>& plant_context ( ) const

Gets the contained plant context.

◆ scene_graph_context()

const systems::Context<double>& scene_graph_context ( ) const

Gets the contained scene graph context.


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