NEURON
nrnpython.h File Reference
#include "neuron/container/data_handle.hpp"
#include "neuron/container/generic_data_handle.hpp"
#include <../../nrnconf.h>
#include <string_view>

Go to the source code of this file.

Classes

struct  NPySecObj
 

Namespaces

 PyHoc
 

Macros

#define PyString_FromString   PyUnicode_FromString
 
#define PyInt_Check   PyLong_Check
 
#define PyInt_CheckExact   PyLong_CheckExact
 
#define PyInt_AS_LONG   PyLong_AsLong
 
#define PyInt_AsLong   PyLong_AsLong
 
#define PyInt_FromLong   PyLong_FromLong
 
#define castptr2long   (long)
 

Enumerations

enum  PyHoc::ObjectType {
  PyHoc::HocTopLevelInterpreter = 0 , PyHoc::HocObject = 1 , PyHoc::HocFunction = 2 , PyHoc::HocArray = 3 ,
  PyHoc::HocRefNum = 4 , PyHoc::HocRefStr = 5 , PyHoc::HocRefObj = 6 , PyHoc::HocForallSectionIterator = 7 ,
  PyHoc::HocSectionListIterator = 8 , PyHoc::HocScalarPtr = 9 , PyHoc::HocArrayIncomplete = 10 , PyHoc::HocRefPStr = 11
}
 
enum  PyHoc::IteratorState { PyHoc::Begin , PyHoc::NextNotLast , PyHoc::Last }
 

Functions

PyObjectnrnpy_hoc_pop (const char *mes)
 
int nrnpy_numbercheck (PyObject *)
 
PyObjecthocobj_call_arg (int)
 
NPySecObjnewpysechelp (Section *sec)
 
PyObjectnrnpy_hoc2pyobject (Object *ho)
 
int nrnpy_ho_eq_po (Object *, PyObject *)
 
PyObjectnrnpy_ho2po (Object *)
 
Objectnrnpy_po2ho (PyObject *)
 
Objectnrnpy_pyobject_in_obj (PyObject *)
 
bool nrn_chk_data_handle (const neuron::container::data_handle< double > &)
 
PyObjectnrn_hocobj_handle (neuron::container::data_handle< double > d)
 
PyObjectnrn_hocobj_ptr (double *)
 
int nrn_is_hocobj_ptr (PyObject *, neuron::container::data_handle< double > &)
 
int nrn_pointer_assign (Prop *, Symbol *, PyObject *)
 
neuron::container::generic_data_handlenrnpy_setpointer_helper (PyObject *, PyObject *)
 

Macro Definition Documentation

◆ castptr2long

#define castptr2long   (long)

Definition at line 39 of file nrnpython.h.

◆ PyInt_AS_LONG

#define PyInt_AS_LONG   PyLong_AsLong

Definition at line 26 of file nrnpython.h.

◆ PyInt_AsLong

#define PyInt_AsLong   PyLong_AsLong

Definition at line 27 of file nrnpython.h.

◆ PyInt_Check

#define PyInt_Check   PyLong_Check

Definition at line 24 of file nrnpython.h.

◆ PyInt_CheckExact

#define PyInt_CheckExact   PyLong_CheckExact

Definition at line 25 of file nrnpython.h.

◆ PyInt_FromLong

#define PyInt_FromLong   PyLong_FromLong

Definition at line 28 of file nrnpython.h.

◆ PyString_FromString

#define PyString_FromString   PyUnicode_FromString

Definition at line 23 of file nrnpython.h.

Function Documentation

◆ hocobj_call_arg()

PyObject* hocobj_call_arg ( int  i)

Definition at line 778 of file nrnpy_hoc.cpp.

◆ newpysechelp()

NPySecObj* newpysechelp ( Section sec)

Definition at line 1043 of file nrnpy_nrn.cpp.

◆ nrn_chk_data_handle()

bool nrn_chk_data_handle ( const neuron::container::data_handle< double > &  pd)

Definition at line 182 of file nrnpy_hoc.cpp.

◆ nrn_hocobj_handle()

PyObject* nrn_hocobj_handle ( neuron::container::data_handle< double >  d)

Definition at line 957 of file nrnpy_hoc.cpp.

◆ nrn_hocobj_ptr()

PyObject* nrn_hocobj_ptr ( double *  pd)

Definition at line 966 of file nrnpy_hoc.cpp.

◆ nrn_is_hocobj_ptr()

int nrn_is_hocobj_ptr ( PyObject po,
neuron::container::data_handle< double > &  pd 
)

Definition at line 970 of file nrnpy_hoc.cpp.

◆ nrn_pointer_assign()

int nrn_pointer_assign ( Prop prop,
Symbol sym,
PyObject value 
)

Definition at line 2308 of file nrnpy_nrn.cpp.

◆ nrnpy_ho2po()

PyObject* nrnpy_ho2po ( Object o)

Definition at line 566 of file nrnpy_hoc.cpp.

◆ nrnpy_ho_eq_po()

int nrnpy_ho_eq_po ( Object ho,
PyObject po 
)

Definition at line 61 of file nrnpy_p2h.cpp.

◆ nrnpy_hoc2pyobject()

PyObject* nrnpy_hoc2pyobject ( Object ho)

Definition at line 77 of file nrnpy_p2h.cpp.

◆ nrnpy_hoc_pop()

PyObject* nrnpy_hoc_pop ( const char *  mes)

Definition at line 620 of file nrnpy_hoc.cpp.

◆ nrnpy_numbercheck()

int nrnpy_numbercheck ( PyObject po)

Definition at line 542 of file nrnpy_hoc.cpp.

◆ nrnpy_po2ho()

Object* nrnpy_po2ho ( PyObject po)

Definition at line 592 of file nrnpy_hoc.cpp.

◆ nrnpy_pyobject_in_obj()

Object* nrnpy_pyobject_in_obj ( PyObject po)

Definition at line 91 of file nrnpy_p2h.cpp.

◆ nrnpy_setpointer_helper()

neuron::container::generic_data_handle* nrnpy_setpointer_helper ( PyObject pyname,
PyObject mech 
)

Definition at line 2626 of file nrnpy_nrn.cpp.