19 #ifndef __ROSEE_ACTION_H 20 #define __ROSEE_ACTION_H 25 #include <yaml-cpp/yaml.h> 40 typedef std::map <std::string, std::vector <double> >
JointPos;
43 std::ostream&
operator << (std::ostream& output,
const JointPos jp) ;
45 JointPos
operator * (
double multiplier, JointPos jp) ;
47 JointPos
operator * ( JointPos jp,
double multiplier ) ;
49 JointPos&
operator *= ( JointPos& jp,
double multiplier ) ;
51 JointPos
operator + ( JointPos jp1, JointPos jp2) ;
65 std::ostream&
operator << (std::ostream& output,
const JointsInvolvedCount jic);
75 typedef std::shared_ptr<Action>
Ptr;
76 typedef std::shared_ptr<const Action>
ConstPtr;
121 virtual std::vector < ROSEE::JointPos >
getAllJointPos ()
const = 0;
124 virtual void print ()
const ;
133 virtual void emitYaml ( YAML::Emitter& out )
const = 0;
139 virtual bool fillFromYaml ( YAML::const_iterator yamlIt ) = 0;
161 #endif // __ROSEE_ACTION_H std::string getName() const
Get the name of the action.
Type
Enum useful to discriminate each action when, for example, we want to parse a file if you change thi...
std::shared_ptr< const Action > ConstPtr
std::map< std::string, std::vector< double > > JointPos
The map to describe the position of all actuated joints.
std::map< std::string, unsigned int > JointsInvolvedCount
The map to describe, how many times a joint is set by the action.
The pure virtual class representing an Action.
virtual void print() const
Overridable functions, if we want to make them more action-specific.
JointPos operator+(JointPos jp1, JointPos jp2)
JointsInvolvedCount getJointsInvolvedCount() const
Get for jointsInvolvedCount.
virtual bool fillFromYaml(YAML::const_iterator yamlIt)=0
function to fill members of the Action with infos taken from yaml files
std::ostream & operator<<(std::ostream &output, const JointPos jp)
operator overload for JointPos so it is easier to print
virtual void emitYaml(YAML::Emitter &out) const =0
Function to fill the argument passed with info about the action.
std::set< std::string > getFingersInvolved() const
Get for fingersInvolved.
JointsInvolvedCount jointsInvolvedCount
JointPos & operator*=(JointPos &jp, double multiplier)
virtual JointPos getJointPos() const =0
Get the position related to this action.
std::shared_ptr< Action > Ptr
JointPos & operator+=(JointPos &jp1, ROSEE::JointPos jp2)
virtual std::vector< ROSEE::JointPos > getAllJointPos() const =0
Return all the joint position stored.
std::set< std::string > fingersInvolved
JointPos operator*(double multiplier, JointPos jp)