Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
moveit::task_constructor::Stage Class Reference

#include <stage.h>

Inheritance diagram for moveit::task_constructor::Stage:
Inheritance graph
[legend]

Public Types

using pointer = std::unique_ptr< Stage >
 
enum  PropertyInitializerSource : uint8_t { DEFAULT = 0, MANUAL = 1, PARENT = 2, INTERFACE = 4 }
 
using SolutionCallback = std::function< void(const SolutionBase &)>
 
using SolutionCallbackList = std::list< SolutionCallback >
 

Public Member Functions

SolutionCallbackList::const_iterator addSolutionCallback (SolutionCallback &&cb)
 add function to be called for every newly found solution or failure More...
 
virtual bool explainFailure (std::ostream &) const
 
const std::list< SolutionBaseConstPtr > & failures () const
 
std::set< std::string > forwardedProperties () const
 
void forwardProperties (const InterfaceState &source, InterfaceState &dest)
 forwarding of properties between interface states More...
 
double getTotalComputeTime () const
 
virtual void init (const moveit::core::RobotModelConstPtr &robot_model)
 
Introspectionintrospection () const
 
uint32_t introspectionId () const
 
const std::string & markerNS ()
 marker namespace of solution markers More...
 
const std::string & name () const
 
size_t numFailures () const
 
const ContainerBaseparent () const
 
PropertyMapproperties ()
 Get the stage's property map. More...
 
const PropertyMapproperties () const
 
void removeSolutionCallback (SolutionCallbackList::const_iterator which)
 remove function callback More...
 
void reportPropertyError (const Property::error &e)
 Analyze source of error and report accordingly. More...
 
virtual void reset ()
 reset stage, clearing all solutions, interfaces, inherited properties. More...
 
void setCostTerm (const CostTermConstPtr &term)
 
template<typename T , typename = std::enable_if_t<std::is_constructible<LambdaCostTerm, T>::value>>
void setCostTerm (T term)
 
void setForwardedProperties (const std::set< std::string > &names)
 
void setMarkerNS (const std::string &marker_ns)
 
void setName (const std::string &name)
 
void setProperty (const std::string &name, const boost::any &value)
 Set a previously declared property to a new value. More...
 
void setProperty (const std::string &name, const char *value)
 overload: const char* values are stored as std::string More...
 
void setTimeout (double timeout)
 
void setTrajectoryExecutionInfo (TrajectoryExecutionInfo trajectory_execution_info)
 Set and get info to use when executing the stage's trajectory. More...
 
void silentFailure ()
 Call to increase number of failures w/o storing a (failure) trajectory. More...
 
const ordered< SolutionBaseConstPtr > & solutions () const
 
bool storeFailures () const
 Should we generate failure solutions? Note: Always report a failure! More...
 
double timeout () const
 timeout of stage per computation More...
 
TrajectoryExecutionInfo trajectoryExecutionInfo () const
 
virtual ~Stage ()
 

Protected Member Functions

 Stage (const Stage &)=delete
 Stage cannot be copied. More...
 
 Stage (StagePrivate *impl)
 Stage can only be instantiated through derived classes. More...
 

Protected Attributes

StagePrivate * pimpl_
 

Detailed Description

Definition at line 146 of file stage.h.

Member Typedef Documentation

◆ pointer

Definition at line 150 of file stage.h.

◆ SolutionCallback

Definition at line 221 of file stage.h.

◆ SolutionCallbackList

Definition at line 222 of file stage.h.

Member Enumeration Documentation

◆ PropertyInitializerSource

Names for property initialization sources

  • INTERFACE allows to pass properties from one stage to the next (in a SerialContainer).
  • PARENT allows to inherit properties from the parent.

INTERFACE takes precedence over PARENT.

Enumerator
DEFAULT 
MANUAL 
PARENT 
INTERFACE 

Definition at line 158 of file stage.h.

Constructor & Destructor Documentation

◆ ~Stage()

moveit::task_constructor::Stage::~Stage ( )
virtual

Definition at line 387 of file stage.cpp.

◆ Stage() [1/2]

moveit::task_constructor::Stage::Stage ( StagePrivate *  impl)
protected

Stage can only be instantiated through derived classes.

Definition at line 375 of file stage.cpp.

◆ Stage() [2/2]

moveit::task_constructor::Stage::Stage ( const Stage )
protecteddelete

Stage cannot be copied.

Member Function Documentation

◆ addSolutionCallback()

Stage::SolutionCallbackList::const_iterator moveit::task_constructor::Stage::addSolutionCallback ( SolutionCallback &&  cb)

add function to be called for every newly found solution or failure

Definition at line 469 of file stage.cpp.

◆ explainFailure()

virtual bool moveit::task_constructor::Stage::explainFailure ( std::ostream &  ) const
inlinevirtual

Reimplemented in moveit::task_constructor::Task, and moveit::task_constructor::ContainerBase.

Definition at line 245 of file stage.h.

◆ failures()

const std::list< SolutionBaseConstPtr > & moveit::task_constructor::Stage::failures ( ) const

Definition at line 489 of file stage.cpp.

◆ forwardedProperties()

std::set<std::string> moveit::task_constructor::Stage::forwardedProperties ( ) const
inline

Definition at line 216 of file stage.h.

◆ forwardProperties()

void moveit::task_constructor::Stage::forwardProperties ( const InterfaceState source,
InterfaceState dest 
)

forwarding of properties between interface states

Definition at line 459 of file stage.cpp.

◆ getTotalComputeTime()

double moveit::task_constructor::Stage::getTotalComputeTime ( ) const

Definition at line 513 of file stage.cpp.

◆ init()

void moveit::task_constructor::Stage::init ( const moveit::core::RobotModelConstPtr &  robot_model)
virtual

◆ introspection()

Introspection * moveit::task_constructor::Stage::introspection ( ) const

Definition at line 455 of file stage.cpp.

◆ introspectionId()

uint32_t moveit::task_constructor::Stage::introspectionId ( ) const

Definition at line 450 of file stage.cpp.

◆ markerNS()

const std::string& moveit::task_constructor::Stage::markerNS ( )
inline

marker namespace of solution markers

Definition at line 204 of file stage.h.

◆ name()

const std::string & moveit::task_constructor::Stage::name ( ) const

Definition at line 442 of file stage.cpp.

◆ numFailures()

size_t moveit::task_constructor::Stage::numFailures ( ) const

Definition at line 493 of file stage.cpp.

◆ parent()

const ContainerBase * moveit::task_constructor::Stage::parent ( ) const

Definition at line 438 of file stage.cpp.

◆ properties() [1/2]

PropertyMap & moveit::task_constructor::Stage::properties ( )

Get the stage's property map.

Definition at line 505 of file stage.cpp.

◆ properties() [2/2]

const PropertyMap& moveit::task_constructor::Stage::properties ( ) const
inline

Definition at line 249 of file stage.h.

◆ removeSolutionCallback()

void moveit::task_constructor::Stage::removeSolutionCallback ( SolutionCallbackList::const_iterator  which)

remove function callback

Definition at line 474 of file stage.cpp.

◆ reportPropertyError()

void moveit::task_constructor::Stage::reportPropertyError ( const Property::error e)

Analyze source of error and report accordingly.

Definition at line 540 of file stage.cpp.

◆ reset()

void moveit::task_constructor::Stage::reset ( )
virtual

◆ setCostTerm() [1/2]

void moveit::task_constructor::Stage::setCostTerm ( const CostTermConstPtr &  term)

set method to determine costs for solutions of this stage

Definition at line 478 of file stage.cpp.

◆ setCostTerm() [2/2]

template<typename T , typename = std::enable_if_t<std::is_constructible<LambdaCostTerm, T>::value>>
void moveit::task_constructor::Stage::setCostTerm ( term)
inline

Definition at line 233 of file stage.h.

◆ setForwardedProperties()

void moveit::task_constructor::Stage::setForwardedProperties ( const std::set< std::string > &  names)
inline

Definition at line 219 of file stage.h.

◆ setMarkerNS()

void moveit::task_constructor::Stage::setMarkerNS ( const std::string &  marker_ns)
inline

set marker namespace for solutions

Auxiliary markers in this stage should use this namespace

Definition at line 202 of file stage.h.

◆ setName()

void moveit::task_constructor::Stage::setName ( const std::string &  name)

Definition at line 446 of file stage.cpp.

◆ setProperty() [1/2]

void moveit::task_constructor::Stage::setProperty ( const std::string &  name,
const boost::any &  value 
)

Set a previously declared property to a new value.

Definition at line 509 of file stage.cpp.

◆ setProperty() [2/2]

void moveit::task_constructor::Stage::setProperty ( const std::string &  name,
const char *  value 
)
inline

overload: const char* values are stored as std::string

Definition at line 253 of file stage.h.

◆ setTimeout()

void moveit::task_constructor::Stage::setTimeout ( double  timeout)
inline

set computation timeout (in seconds)

The logic of the individual stage should ensure this limit is respected.

Definition at line 194 of file stage.h.

◆ setTrajectoryExecutionInfo()

void moveit::task_constructor::Stage::setTrajectoryExecutionInfo ( TrajectoryExecutionInfo  trajectory_execution_info)
inline

Set and get info to use when executing the stage's trajectory.

Definition at line 207 of file stage.h.

◆ silentFailure()

void moveit::task_constructor::Stage::silentFailure ( )

Call to increase number of failures w/o storing a (failure) trajectory.

Definition at line 497 of file stage.cpp.

◆ solutions()

const ordered< SolutionBaseConstPtr > & moveit::task_constructor::Stage::solutions ( ) const

Definition at line 485 of file stage.cpp.

◆ storeFailures()

bool moveit::task_constructor::Stage::storeFailures ( ) const

Should we generate failure solutions? Note: Always report a failure!

Definition at line 501 of file stage.cpp.

◆ timeout()

double moveit::task_constructor::Stage::timeout ( ) const
inline

timeout of stage per computation

Definition at line 196 of file stage.h.

◆ trajectoryExecutionInfo()

TrajectoryExecutionInfo moveit::task_constructor::Stage::trajectoryExecutionInfo ( ) const
inline

Definition at line 210 of file stage.h.

Member Data Documentation

◆ pimpl_

StagePrivate* moveit::task_constructor::Stage::pimpl_
protected

Definition at line 267 of file stage.h.


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


core
Author(s):
autogenerated on Sat May 3 2025 02:40:11