4 #include <dynamic-graph/entity.h> 5 #include <dynamic-graph/factory.h> 7 #include <dynamic-graph/pool.h> 17 #if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 2)) 18 #pragma GCC diagnostic ignored "-Wstrict-aliasing" 33 using namespace convert;
39 Entity& entity = bp::extract<Entity&>(obj);
41 obj.attr(el.first.c_str()) = bp::object(bp::ptr(el.second));
46 Entity& entity = bp::extract<Entity&>(obj);
51 obj.attr(el.first.c_str()) = bp::object(bp::ptr(el.second));
63 throw std::invalid_argument(
"Found an object named " +
64 std::string(instanceName) +
66 "but this object is of type " +
68 " and not " + std::string(className));
73 std::string(className), std::string(instanceName));
80 Command& command = bp::template extract<Command&>(args[0]);
81 if (bp::len(args) != int(command.
valueTypes().size() + 1))
83 throw std::out_of_range(
"Wrong number of arguments");
84 std::vector<Value> values;
86 for (
int i = 1; i < bp::len(args); ++i)
boost::python::object fromValue(const command::Value &value)
Eigen::Matrix< CustomType< Scalar >, Eigen::Dynamic, Eigen::Dynamic > create(int rows, int cols)
SignalMap getSignalMap() const
void addSignals(bp::object obj)
command::Value toValue(boost::python::object o, const command::Value::Type &type)
virtual const std::string & getClassName() const
bp::object executeCmd(bp::tuple args, bp::dict)
void setParameterValues(const std::vector< Value > &values)
static PoolStorage * getInstance()
CommandMap_t getNewStyleCommandMap()
Entity * newEntity(const std::string &classname, const std::string &objname) const
static FactoryStorage * getInstance()
void addCommands(bp::object obj)
const std::vector< Value::Type > & valueTypes() const