Commit d242f6e6 authored by Joseph Mirabel's avatar Joseph Mirabel
Browse files

Remove signal caster list.

parent 01eaf045
......@@ -54,9 +54,6 @@ PyObject* getStreamPrintPeriod(PyObject* self, PyObject* args);
namespace factory {
PyObject* getEntityClassList(PyObject* self, PyObject* args);
}
namespace signalCaster {
PyObject* getSignalTypeList(PyObject* self, PyObject* args);
}
namespace pool {
PyObject* writeGraph(PyObject* self, PyObject* args);
PyObject* getEntityList(PyObject* self, PyObject* args);
......@@ -133,8 +130,6 @@ __attribute__((unused)) static PyMethodDef dynamicGraphMethods[] = {
"get the doc string of an entity type"},
{"factory_get_entity_class_list", dynamicgraph::python::factory::getEntityClassList, METH_VARARGS,
"return the list of entity classes"},
{"signal_caster_get_type_list", dynamicgraph::python::signalCaster::getSignalTypeList, METH_VARARGS,
"return the list of signal type names"},
{"writeGraph", dynamicgraph::python::pool::writeGraph, METH_VARARGS, "Write the graph of entities in a filename."},
{"get_entity_list", dynamicgraph::python::pool::getEntityList, METH_VARARGS,
"return the list of instanciated entities"},
......
......@@ -12,7 +12,6 @@ ADD_LIBRARY(${PYTHON_MODULE} MODULE
pool-py.cc
python-compat.cc
signal-base-py.cc
signal-caster-py.cc
signal-wrapper.cc
)
......
// Copyright 2010, Florent Lamiraux, Thomas Moulard, LAAS-CNRS.
#include <iostream>
#include <sstream>
#include <dynamic-graph/signal-caster.h>
#include "dynamic-graph/python/dynamic-graph-py.hh"
namespace dynamicgraph {
namespace python {
namespace signalCaster {
PyObject* getSignalTypeList(PyObject* /*self*/, PyObject* args) {
if (!PyArg_ParseTuple(args, "")) return NULL;
std::vector<std::string> typeList = dynamicgraph::SignalCaster::getInstance()->listTypenames();
Py_ssize_t typeNumber = typeList.size();
// Build a tuple object
PyObject* typeTuple = PyTuple_New(typeNumber);
for (Py_ssize_t iType = 0; iType < typeNumber; ++iType) {
PyObject* className = Py_BuildValue("s", typeList[iType].c_str());
PyTuple_SetItem(typeTuple, iType, className);
}
return Py_BuildValue("O", typeTuple);
}
} // namespace signalCaster
} // namespace python
} // namespace dynamicgraph
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment