ROSEndEffector
ROS End-Effector package: provides a ROS-based set of standard interfaces to command robotics end-effectors in an agnostic fashion.
|
The pure virtual class representing an Action. More...
#include <Action.h>
Public Types | |
enum | Type { Primitive, Generic, Composed, Timed, None } |
Enum useful to discriminate each action when, for example, we want to parse a file if you change this enum, change also the ROSEEControl.msg accordingly. More... | |
typedef std::shared_ptr< Action > | Ptr |
typedef std::shared_ptr< const Action > | ConstPtr |
Public Member Functions | |
virtual | ~Action () |
std::string | getName () const |
Get the name of the action. More... | |
Type | getType () const |
std::set< std::string > | getFingersInvolved () const |
Get for fingersInvolved. More... | |
JointsInvolvedCount | getJointsInvolvedCount () const |
Get for jointsInvolvedCount. More... | |
virtual JointPos | getJointPos () const =0 |
Get the position related to this action. More... | |
virtual std::vector< ROSEE::JointPos > | getAllJointPos () const =0 |
Return all the joint position stored. More... | |
virtual void | print () const |
Overridable functions, if we want to make them more action-specific. More... | |
virtual void | emitYaml (YAML::Emitter &out) const =0 |
Function to fill the argument passed with info about the action. More... | |
virtual bool | fillFromYaml (YAML::const_iterator yamlIt)=0 |
function to fill members of the Action with infos taken from yaml files More... | |
Protected Member Functions | |
Action () | |
Action (std::string actionName, Action::Type type) | |
Protected Attributes | |
std::string | name |
Action::Type | type |
std::set< std::string > | fingersInvolved |
JointsInvolvedCount | jointsInvolvedCount |
The pure virtual class representing an Action.
It has members that are in common to all derived class
typedef std::shared_ptr<const Action> ROSEE::Action::ConstPtr |
typedef std::shared_ptr<Action> ROSEE::Action::Ptr |
enum ROSEE::Action::Type |
Enum useful to discriminate each action when, for example, we want to parse a file if you change this enum, change also the ROSEEControl.msg accordingly.
Enumerator | |
---|---|
Primitive | |
Generic | |
Composed | |
Timed | |
None |
Definition at line 82 of file Action.h.
|
protected |
Definition at line 106 of file Action.cpp.
|
protected |
Definition at line 111 of file Action.cpp.
|
pure virtual |
Function to fill the argument passed with info about the action.
Pure virtual because each derived class has different infos and stored differently. check YamlWorker to correctly emit and parse the file
out | the yaml-cpp emitter which store infos about the action |
Implemented in ROSEE::ActionTimed, ROSEE::ActionPinchLoose, ROSEE::ActionComposed, ROSEE::ActionMultiplePinchTight, ROSEE::ActionSingleJointMultipleTips, ROSEE::ActionPinchTight, ROSEE::ActionGeneric, and ROSEE::ActionPrimitive.
|
pure virtual |
function to fill members of the Action with infos taken from yaml files
yamlIt | a YAML::const_iterator to the node that is loaded with YAML::LoadFile(dirPath + filename). check YamlWorker to correctly parse and emit the file |
Implemented in ROSEE::ActionTimed, ROSEE::ActionTrig, ROSEE::ActionComposed, ROSEE::ActionPinchLoose, ROSEE::ActionMultiplePinchTight, ROSEE::ActionGeneric, ROSEE::ActionSingleJointMultipleTips, and ROSEE::ActionPinchTight.
|
pure virtual |
Return all the joint position stored.
If the concrete (derived from Action) has only one joint position info, this function is equal to getJointPos.
Implemented in ROSEE::ActionTrig, ROSEE::ActionGeneric, ROSEE::ActionTimed, ROSEE::ActionMultiplePinchTight, ROSEE::ActionSingleJointMultipleTips, ROSEE::ActionPinchLoose, and ROSEE::ActionPinchTight.
std::set< std::string > ROSEE::Action::getFingersInvolved | ( | ) | const |
Get for fingersInvolved.
Definition at line 125 of file Action.cpp.
|
pure virtual |
Get the position related to this action.
Pure Virtual function: the derived class store this info differently so they are in charge of providing the read.
Implemented in ROSEE::ActionTrig, ROSEE::ActionSingleJointMultipleTips, ROSEE::ActionGeneric, ROSEE::ActionTimed, ROSEE::ActionMultiplePinchTight, ROSEE::ActionPinchLoose, and ROSEE::ActionPinchTight.
ROSEE::JointsInvolvedCount ROSEE::Action::getJointsInvolvedCount | ( | ) | const |
Get for jointsInvolvedCount.
Definition at line 130 of file Action.cpp.
std::string ROSEE::Action::getName | ( | ) | const |
Get the name of the action.
Definition at line 116 of file Action.cpp.
ROSEE::Action::Type ROSEE::Action::getType | ( | ) | const |
Definition at line 120 of file Action.cpp.
|
virtual |
Overridable functions, if we want to make them more action-specific.
Reimplemented in ROSEE::ActionTimed, ROSEE::ActionPinchLoose, ROSEE::ActionMultiplePinchTight, ROSEE::ActionSingleJointMultipleTips, ROSEE::ActionPinchTight, and ROSEE::ActionComposed.
Definition at line 135 of file Action.cpp.
|
protected |
|
protected |
|
protected |