@@ -37,7 +37,7 @@ using sofa::helper::logging::Message;
3737#include < sofa/helper/DiffLib.h>
3838using sofa::helper::getClosestMatch;
3939
40- #include < sofa/simulation/graph/DAGNode .h>
40+ #include < sofa/simulation/Node .h>
4141using sofa::core::ExecParams;
4242
4343#include < SofaPython3/LinkPath.h>
@@ -163,22 +163,20 @@ std::string getLinkPath(Node* node){
163163 return (" @" +node->getPathName ()).c_str ();
164164}
165165
166- py_shared_ptr<Node> __init__noname () {
167- auto dag_node = sofa::core::objectmodel::New<sofa::simulation::Node>(" unnamed" );
168- return std::move (dag_node );
166+ py_shared_ptr<Node> __init_noname__ () {
167+ auto node = sofa::core::objectmodel::New<sofa::simulation::Node>(" unnamed" );
168+ return std::move (node );
169169}
170170
171- py_shared_ptr<Node> __init__ (const std::string& name) {
172- auto dag_node = sofa::core::objectmodel::New<sofa::simulation::Node>(name);
173- return std::move (dag_node );
171+ py_shared_ptr<Node> __init_named__ (const std::string& name) {
172+ auto node = sofa::core::objectmodel::New<sofa::simulation::Node>(name);
173+ return std::move (node );
174174}
175175
176- py_shared_ptr<Node> __init__ (const std::string& name, const py::kwargs& kwargs) {
177- auto dag_node = sofa::core::objectmodel::New<sofa::simulation::graph::DAGNode>(name);
178-
179- setDataFromKwargs (dag_node.get (), kwargs);
180-
181- return std::move (dag_node);
176+ py_shared_ptr<Node> __init_kwarged__ (const std::string& name, const py::kwargs& kwargs) {
177+ auto node = sofa::core::objectmodel::New<sofa::simulation::Node>(name);
178+ setDataFromKwargs (node.get (), kwargs);
179+ return std::move (node);
182180}
183181
184182// / Method: init (beware this is not the python __init__, this is sofa's init())
@@ -687,9 +685,9 @@ void moduleAddNode(py::module &m) {
687685 return py::cast (dynamic_cast <Node*>(object->toBaseNode ()));
688686 });
689687
690- p.def (py::init (&__init__noname ), sofapython3::doc::sofa::core::Node::init);
691- p.def (py::init (&__init__no_kwargs__ ), sofapython3::doc::sofa::core::Node::init1Arg, py::arg (" name" ));
692- p.def (py::init (&__init__ ), sofapython3::doc::sofa::core::Node::init1Arg);
688+ p.def (py::init (&__init_noname__ ), sofapython3::doc::sofa::core::Node::init);
689+ p.def (py::init (&__init_named__ ), sofapython3::doc::sofa::core::Node::init1Arg, py::arg (" name" ));
690+ p.def (py::init (&__init_kwarged__ ), sofapython3::doc::sofa::core::Node::init1Arg, py::arg ( " name " ) );
693691 p.def (" init" , &init, sofapython3::doc::sofa::core::Node::initSofa );
694692 p.def (" add" , &addKwargs, sofapython3::doc::sofa::core::Node::addKwargs);
695693 p.def (" addObject" , &addObjectKwargs, sofapython3::doc::sofa::core::Node::addObjectKwargs);
0 commit comments