| Line |
Branch |
Exec |
Source |
| 1 |
|
|
/* |
| 2 |
|
|
* Copyright 2010, |
| 3 |
|
|
* Florent Lamiraux |
| 4 |
|
|
* |
| 5 |
|
|
* CNRS/AIST |
| 6 |
|
|
* |
| 7 |
|
|
*/ |
| 8 |
|
|
|
| 9 |
|
|
#ifndef FEATURE_JOINT_LIMITS_COMMAND_H |
| 10 |
|
|
#define FEATURE_JOINT_LIMITS_COMMAND_H |
| 11 |
|
|
|
| 12 |
|
|
#include <dynamic-graph/command-getter.h> |
| 13 |
|
|
#include <dynamic-graph/command-setter.h> |
| 14 |
|
|
#include <dynamic-graph/command.h> |
| 15 |
|
|
|
| 16 |
|
|
#include <boost/assign/list_of.hpp> |
| 17 |
|
|
|
| 18 |
|
|
namespace dynamicgraph { |
| 19 |
|
|
namespace sot { |
| 20 |
|
|
namespace command { |
| 21 |
|
|
namespace featureJointLimits { |
| 22 |
|
|
using ::dynamicgraph::command::Command; |
| 23 |
|
|
using ::dynamicgraph::command::Value; |
| 24 |
|
|
|
| 25 |
|
|
// Command Actuate |
| 26 |
|
|
class Actuate : public Command { |
| 27 |
|
|
public: |
| 28 |
|
✗ |
virtual ~Actuate() {} |
| 29 |
|
|
/// Create command and store it in Entity |
| 30 |
|
|
/// \param entity instance of Entity owning this command |
| 31 |
|
|
/// \param docstring documentation of the command |
| 32 |
|
✗ |
Actuate(FeatureJointLimits &entity, const std::string &docstring) |
| 33 |
|
✗ |
: Command(entity, std::vector<Value::Type>(), docstring) {} |
| 34 |
|
✗ |
virtual Value doExecute() { |
| 35 |
|
✗ |
FeatureJointLimits &fjl = static_cast<FeatureJointLimits &>(owner()); |
| 36 |
|
✗ |
Flags fl(63); // 0x0000003f = 00000000000000000000000000111111 |
| 37 |
|
✗ |
fjl.selectionSIN = (!fl); |
| 38 |
|
|
// return void |
| 39 |
|
✗ |
return Value(); |
| 40 |
|
|
} |
| 41 |
|
|
}; // class Actuate |
| 42 |
|
|
} // namespace featureJointLimits |
| 43 |
|
|
} // namespace command |
| 44 |
|
|
} /* namespace sot */ |
| 45 |
|
|
} /* namespace dynamicgraph */ |
| 46 |
|
|
|
| 47 |
|
|
#endif // FEATURE_JOINT_LIMITS_COMMAND_H |
| 48 |
|
|
|