
#include "gzBasicTypes.h"
Go to the source code of this file.
Classes | |
| class | gzType |
| class | gzTypeInterface |
Defines | |
| #define | GZ_DECLARE_TYPE_INTERFACE_EXPORT(exporter) |
| #define | GZ_DECLARE_TYPE_INTERFACE |
| #define | GZ_DECLARE_TYPE_BASE(base, name) gzType base::s_type(0,name) |
| #define | GZ_DECLARE_TYPE_CHILD(parent, child, name) gzType child::s_type(&parent::s_type,name) |
Typedefs | |
| typedef gzType * | gzTypePtr |
| Type definition pointer. | |
Functions | |
| template<class T> | |
| T * | gzDynamic_Cast (gzTypeInterface *pObject) |
| template<class T1, class T2> | |
| T2 * | gzDynamic_Instance_Cast (gzTypeInterface *pObject) |
Variables | |
| const gzULong | GZ_TYPE_MAX_NAME_LEN = 100 |
Gizmo3D uses the gzTypeInterface to query a certain object of its type. It can also manage hierarchical inheritance not nessecary the same as the C++ inheritance.
You should use it like this.
class MyClass : public gzTypeInterface { public: MyClass(){}; // or whatever virtual ~MyClass(){}; // or whatever GZ_DECLARE_TYPE_INTERFACE; // This is IMPORTANT };
You Should also in the implementation file write this.
GZ_DECLARE_TYPE_BASE(gzMyClass,"MyClassName"); // or if you have derived it from another class GZ_DECLARE_TYPE_CHILD(MyParentClass,MyClass,"MyClassName");
Definition in file gzType.h.
|
|
|
|
|
|
|
|
Value: static gzType s_type;\ static gzType *getClassType() { return &s_type; }\ virtual gzType *getType() const { return getClassType(); }
|
|
|
Value: |
|
|
Type definition pointer.
|
|
||||||||||
|
Definition at line 175 of file gzType.h. References gzTypeInterface::isOfType(), and NULL. |
|
||||||||||
|
Definition at line 200 of file gzType.h. References gzTypeInterface::isOfType(), and NULL. |
|
|
|