38 if (!PyArg_ParseTuple(args,
const_cast<char *
>(
"O!O!|O!i:TDirectory::WriteObject"),
46 PyErr_SetString(PyExc_TypeError,
47 "TDirectory::WriteObject must be called with a TDirectory instance as first argument");
51 if (option !=
nullptr) {
75 if (!PyObject_IsTrue(result)) {
77 PyObject *stypestr = PyObject_Str(PyObject_Type(self));
87 PyObject_SetAttr(self, attr, result);
102 PyObject *pyclass = PyTuple_GetItem(args, 0);
113 PyObject *pyclass = PyTuple_GetItem(args, 0);
#define CPyCppyy_PyText_AsString
#define CPyCppyy_PyText_Type
TClass * GetTClass(const CPyCppyy::CPPInstance *pyobj)
PyObject * CallPyObjMethod(PyObject *obj, const char *meth)
Set of helper functions that are invoked from the C++ implementation of pythonizations.
PyObject * TDirectoryWriteObject(CPPInstance *self, PyObject *args)
Implements the WriteObject method of TDirectory This method allows to write objects into TDirectory i...
PyObject * TDirectoryGetAttr(PyObject *self, PyObject *attr)
Implements a getter to assign to TDirectory.__getattr__ Method that is assigned to TDirectory....
void * DynamicCast(const TClass *base, void *obj, Bool_t up=kTRUE)
Cast obj of this class type up to baseclass cl if up is true.
Describe directory structure in memory.
bool AddToClass(PyObject *pyclass, const char *label, PyCFunction cfunc, int flags=METH_VARARGS)
PyTypeObject CPPInstance_Type
PyObject * AddDirectoryWritePyz(PyObject *self, PyObject *args)
Add pythonisation of TDirectory::WriteObject.
PyObject * AddDirectoryGetAttrPyz(PyObject *self, PyObject *args)
Add attr syntax to TDirectory.