#include <mvsim/basic_types.h>
#include <map>
#include <stdexcept>
#include <string>
Go to the source code of this file.
|
#define | DECLARES_REGISTER_CLASS1(CLASS_NAME, BASE_CLASS, ARG1) |
|
#define | DECLARES_REGISTER_CLASS2(CLASS_NAME, BASE_CLASS, ARG1, ARG2) |
|
#define | REGISTER_CLASS1(FACTORY_TYPE, FACTORY_OBJ, TEXTUAL_NAME, CLASS_NAME) |
|
#define | REGISTER_CLASS2(FACTORY_TYPE, FACTORY_OBJ, TEXTUAL_NAME, CLASS_NAME) |
|
#define DECLARES_REGISTER_CLASS1 |
( |
|
CLASS_NAME, |
|
|
|
BASE_CLASS, |
|
|
|
ARG1 |
|
) |
| |
Value:public: \
static BASE_CLASS* Create(ARG1 a1) { return new CLASS_NAME(a1); }
Definition at line 71 of file ClassFactory.h.
#define DECLARES_REGISTER_CLASS2 |
( |
|
CLASS_NAME, |
|
|
|
BASE_CLASS, |
|
|
|
ARG1, |
|
|
|
ARG2 |
|
) |
| |
Value:public: \
static BASE_CLASS* Create(ARG1 a1, ARG2 a2) \
{ \
return new CLASS_NAME(a1, a2); \
}
Definition at line 74 of file ClassFactory.h.
#define REGISTER_CLASS1 |
( |
|
FACTORY_TYPE, |
|
|
|
FACTORY_OBJ, |
|
|
|
TEXTUAL_NAME, |
|
|
|
CLASS_NAME |
|
) |
| |
Value:{ \
FACTORY_TYPE::TClassData data; \
data.ptr_factory1 = &CLASS_NAME::Create; \
FACTORY_OBJ.do_register(TEXTUAL_NAME, data); \
}
Definition at line 81 of file ClassFactory.h.
#define REGISTER_CLASS2 |
( |
|
FACTORY_TYPE, |
|
|
|
FACTORY_OBJ, |
|
|
|
TEXTUAL_NAME, |
|
|
|
CLASS_NAME |
|
) |
| |
Value:{ \
FACTORY_TYPE::TClassData data; \
data.ptr_factory2 = &CLASS_NAME::Create; \
FACTORY_OBJ.do_register(TEXTUAL_NAME, data); \
}
Definition at line 88 of file ClassFactory.h.