Crossfire Server, Branches 1.12  R18729
cfpython_archetype_private.h
Go to the documentation of this file.
1 static PyObject *Crossfire_Archetype_GetName(Crossfire_Archetype *whoptr, void *closure);
2 static PyObject *Crossfire_Archetype_GetNext(Crossfire_Archetype *who, void *closure);
3 static PyObject *Crossfire_Archetype_GetMore(Crossfire_Archetype *who, void *closure);
4 static PyObject *Crossfire_Archetype_GetHead(Crossfire_Archetype *who, void *closure);
5 static PyObject *Crossfire_Archetype_GetClone(Crossfire_Archetype *who, void *closure);
6 static PyObject *Crossfire_Archetype_GetNewObject(Crossfire_Archetype *who, PyObject *args);
8 
9 static PyGetSetDef Archetype_getseters[] = {
10  { "Name", (getter)Crossfire_Archetype_GetName, NULL, NULL, NULL },
11  { "Next", (getter)Crossfire_Archetype_GetNext, NULL, NULL, NULL },
12  { "More", (getter)Crossfire_Archetype_GetMore, NULL, NULL, NULL },
13  { "Head", (getter)Crossfire_Archetype_GetHead, NULL, NULL, NULL },
14  { "Clone", (getter)Crossfire_Archetype_GetClone, NULL, NULL, NULL },
15  { NULL, NULL, NULL, NULL, NULL }
16 };
17 
18 static PyMethodDef ArchetypeMethods[] = {
19  { "NewObject", (PyCFunction)Crossfire_Archetype_GetNewObject, METH_NOARGS, NULL },
20  { NULL, NULL, 0, NULL }
21 };
22 
23 /* Our actual Python ArchetypeType */
24 PyTypeObject Crossfire_ArchetypeType = {
25  PyObject_HEAD_INIT(NULL)
26 #ifndef IS_PY3K
27  0, /* ob_size*/
28 #endif
29  "Crossfire.Archetype", /* tp_name*/
30  sizeof(Crossfire_Archetype), /* tp_basicsize*/
31  0, /* tp_itemsize*/
32  NULL, /* tp_dealloc*/
33  NULL, /* tp_print*/
34  NULL, /* tp_getattr*/
35  NULL, /* tp_setattr*/
36  (cmpfunc)Crossfire_Archetype_InternalCompare, /* tp_compare*/
37  NULL, /* tp_repr*/
38  NULL, /* tp_as_number*/
39  NULL, /* tp_as_sequence*/
40  NULL, /* tp_as_mapping*/
41  PyObject_HashNotImplemented, /* tp_hash */
42  NULL, /* tp_call*/
43  NULL, /* tp_str*/
44  PyObject_GenericGetAttr, /* tp_getattro*/
45  PyObject_GenericSetAttr, /* tp_setattro*/
46  NULL, /* tp_as_buffer*/
47  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE, /* tp_flags*/
48  "Crossfire archetypes", /* tp_doc */
49  NULL, /* tp_traverse */
50  NULL, /* tp_clear */
51  NULL, /* tp_richcompare */
52  0, /* tp_weaklistoffset */
53  NULL, /* tp_iter */
54  NULL, /* tp_iternext */
55  ArchetypeMethods, /* tp_methods */
56  NULL, /* tp_members */
57  Archetype_getseters, /* tp_getset */
58  NULL, /* tp_base */
59  NULL, /* tp_dict */
60  NULL, /* tp_descr_get */
61  NULL, /* tp_descr_set */
62  0, /* tp_dictoffset */
63  NULL, /* tp_init */
64  NULL, /* tp_alloc */
65  NULL, /* tp_new */
66  NULL, /* tp_free */
67  NULL, /* tp_is_gc */
68  NULL, /* tp_bases */
69  NULL, /* tp_mro */
70  NULL, /* tp_cache */
71  NULL, /* tp_subclasses */
72  NULL, /* tp_weaklist */
73  NULL, /* tp_del */
74 };
static int Crossfire_Archetype_InternalCompare(Crossfire_Archetype *left, Crossfire_Archetype *right)
static PyObject * Crossfire_Archetype_GetNext(Crossfire_Archetype *who, void *closure)
static PyGetSetDef Archetype_getseters[]
static PyObject * Crossfire_Archetype_GetClone(Crossfire_Archetype *who, void *closure)
static PyMethodDef ArchetypeMethods[]
#define PyObject_HashNotImplemented
Definition: cfpython.h:73
static PyObject * Crossfire_Archetype_GetMore(Crossfire_Archetype *who, void *closure)
PyTypeObject Crossfire_ArchetypeType
static PyObject * Crossfire_Archetype_GetHead(Crossfire_Archetype *who, void *closure)
static PyObject * Crossfire_Archetype_GetName(Crossfire_Archetype *whoptr, void *closure)
static PyObject * Crossfire_Archetype_GetNewObject(Crossfire_Archetype *who, PyObject *args)