removed time() methods for class Reactor and added them to class ReactorNet

This commit is contained in:
Dave Goodwin
2004-07-29 22:22:46 +00:00
parent dd0456eb62
commit 3ec6010d51
2 changed files with 21 additions and 10 deletions

View File

@@ -101,15 +101,15 @@ py_reactor_setKineticsMgr(PyObject *self, PyObject *args)
// return Py_BuildValue("d",reactor_step(n, t));
// }
static PyObject*
py_reactor_time(PyObject *self, PyObject *args)
{
int n;
if (!PyArg_ParseTuple(args, "i:reactor_time", &n))
return NULL;
double t = reactor_time(n);
return Py_BuildValue("d",t);
}
// static PyObject*
// py_reactor_time(PyObject *self, PyObject *args)
// {
// int n;
// if (!PyArg_ParseTuple(args, "i:reactor_time", &n))
// return NULL;
// double t = reactor_time(n);
// return Py_BuildValue("d",t);
// }
static PyObject*
py_reactor_mass(PyObject *self, PyObject *args)
@@ -504,6 +504,16 @@ py_reactornet_setInitialTime(PyObject *self, PyObject *args)
return Py_BuildValue("i",0);
}
static PyObject*
py_reactornet_time(PyObject *self, PyObject *args)
{
int n;
if (!PyArg_ParseTuple(args, "i:reactornet_time", &n))
return NULL;
double t = reactornet_time(n);
return Py_BuildValue("d",t);
}
static PyObject*
py_reactornet_addreactor(PyObject *self, PyObject *args)
{

View File

@@ -207,7 +207,8 @@ static PyMethodDef ct_methods[] = {
{"reactor_setThermoMgr", py_reactor_setThermoMgr, METH_VARARGS},
{"reactor_setEnergy", py_reactor_setEnergy, METH_VARARGS},
{"reactor_volume", py_reactor_volume, METH_VARARGS},
{"reactor_time", py_reactor_time, METH_VARARGS},
//{"reactor_time", py_reactor_time, METH_VARARGS},
{"reactornet_time", py_reactornet_time, METH_VARARGS},
// {"reactor_advance", py_reactor_advance, METH_VARARGS},
//{"reactor_step", py_reactor_step, METH_VARARGS},
{"reactornet_addreactor", py_reactornet_addreactor, METH_VARARGS},