RobWorkProject  23.9.11-
Public Types | Public Member Functions | Protected Member Functions | List of all members
Motion< T > Class Template Referenceabstract

Specified the template based interface of a motion. More...

#include <Motion.hpp>

Inherits MotionBase.

Inherited by CircularMotion< T >, LinearMotion< T >, and P2PMotion< T >.

Public Types

typedef rw::core::Ptr< Motion< T > > Ptr
 smart pointer type to this class
 
typedef rw::core::Ptr< Target< T > > TargetPtr
 
- Public Types inherited from MotionBase
typedef rw::core::Ptr< MotionBasePtr
 smart pointer type to this class
 
- Public Types inherited from Entity
typedef rw::core::Ptr< EntityPtr
 smart pointer type to this class
 

Public Member Functions

virtual const T & start ()=0
 Returns value of the start target. More...
 
virtual const T & end ()=0
 Returns value of the end target. More...
 
virtual TargetPtr startTarget ()=0
 Returns the start target. More...
 
virtual TargetPtr endTarget ()=0
 Returns the end target. More...
 
virtual rw::core::Ptr< Motion< T > > clone (const std::vector< TargetPtr > &newTargets)=0
 Make a copy of the motion. More...
 
virtual void reverse ()=0
 Do reverse motion.
 
- Public Member Functions inherited from MotionBase
 MotionBase (MotionType motionType)
 Constructs motion. More...
 
virtual ~MotionBase ()
 Destructor.
 
MotionType motionType ()
 Returns the type of the motion. More...
 
- Public Member Functions inherited from Entity
 Entity (EntityType type, const std::string &id="")
 Constructs an Entity with a given type,. More...
 
virtual ~Entity ()
 Destructor.
 
rw::core::PropertyMapgetPropertyMap ()
 Returns reference to rw::core::PropertyMap associated with the Entity. More...
 
const rw::core::PropertyMapgetPropertyMap () const
 Returns reference to rw::core::PropertyMap associated with the Entity. More...
 
void setPropertyMap (const rw::core::PropertyMap &propertymap)
 Sets the content of the propertymap. More...
 
int getIndex () const
 Returns index specifying the position of the Entity in a Task. More...
 
void setIndex (int index)
 Sets the order index of the Entity. More...
 
virtual EntityType entityType () const
 Returns the type of Entity. More...
 
void setId (const std::string &id)
 Set the id for the entity. More...
 
const std::string & getId () const
 Get the id of the entity. More...
 
template<class T >
cast ()
 Method which can be used to explicitly and safely casting an Entity. More...
 

Protected Member Functions

 Motion (MotionType motion_type)
 Protected constructor.
 

Additional Inherited Members

- Protected Attributes inherited from Entity
rw::core::PropertyMap _properties
 Properties of entity.
 
EntityType _entityType
 The type of entity.
 
int _index
 The index of the entity.
 
std::string _id
 The id of the entity.
 

Detailed Description

template<class T>
class rwlibs::task::Motion< T >

Specified the template based interface of a motion.

This class is abstract.

Member Typedef Documentation

◆ TargetPtr

Convenient typedef of pointer to target of type T

Member Function Documentation

◆ clone()

virtual rw::core::Ptr<Motion<T> > clone ( const std::vector< TargetPtr > &  newTargets)
pure virtual

Make a copy of the motion.

Parameters
newTargets[in] a vector of targets.
Returns
new identical motion.

Implemented in CircularMotion< T >, LinearMotion< T >, and P2PMotion< T >.

◆ end()

virtual const T& end ( )
pure virtual

Returns value of the end target.

Returns
Reference to value of end target

Implemented in CircularMotion< T >, LinearMotion< T >, and P2PMotion< T >.

◆ endTarget()

virtual TargetPtr endTarget ( )
pure virtual

Returns the end target.

Returns
The start target

Implemented in CircularMotion< T >, LinearMotion< T >, and P2PMotion< T >.

◆ start()

virtual const T& start ( )
pure virtual

Returns value of the start target.

Returns
Reference to value of start target

Implemented in CircularMotion< T >, LinearMotion< T >, and P2PMotion< T >.

◆ startTarget()

virtual TargetPtr startTarget ( )
pure virtual

Returns the start target.

Returns
The start target

Implemented in CircularMotion< T >, LinearMotion< T >, and P2PMotion< T >.


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