libcrn
3.9.5
A document image processing library
|
Classes | |
class | crn::ModuleManager< Category > |
A dynamic module manager. More... | |
Macros | |
#define | CRN_MODULE_ENTRY_POINT(category) crn_module_get_##category |
Internal. More... | |
#define | CRN_MODULE_ENTRY_POINT_AS_STRING(category) "crn_module_get_"#category |
Internal. More... | |
#define | CRN_DECLARE_MODULE(categoryname) public: static const char* GetModuleEntryPoint() { return CRN_MODULE_ENTRY_POINT_AS_STRING(categoryname); } |
Declares that the current class is a base for dynamic modules. More... | |
#define | CRN_BEGIN_MODULE(classname, categoryname) class classname: public categoryname { |
Begins the declaration of a module. More... | |
#define | CRN_END_MODULE(classname, categoryname) }; extern "C" categoryname* CRN_MODULE_ENTRY_POINT(categoryname)() { return new classname; } |
End the declaration and registration of a module. More... | |
#define CRN_BEGIN_MODULE | ( | classname, | |
categoryname | |||
) | class classname: public categoryname { |
Begins the declaration of a module.
Begins the declaration of a module.
A binary file may contain only one module. Use this macro in a .cpp file.
Example:
CRN_BEGIN_MODULE(Meow, AnimalTalk)
public:
Meow();
virtual void Talk();
CRN_END_MODULE(Meow, AnimalTalk)
[in] | classname | the name of the class to register |
[in] | categoryname | the name of the interface (abstract base class of classname) |
Definition at line 212 of file CRNModule.h.
#define CRN_DECLARE_MODULE | ( | categoryname | ) | public: static const char* GetModuleEntryPoint() { return CRN_MODULE_ENTRY_POINT_AS_STRING(categoryname); } |
Declares that the current class is a base for dynamic modules.
Declares that the current class is a base for dynamic modules.
[in] | categoryname | the name of the class being declared as a base for dynamic modules. |
Definition at line 192 of file CRNModule.h.
#define CRN_END_MODULE | ( | classname, | |
categoryname | |||
) | }; extern "C" categoryname* CRN_MODULE_ENTRY_POINT(categoryname)() { return new classname; } |
End the declaration and registration of a module.
End the declaration and registration of a module.
A binary file may contain only one module. Use this macro in a .cpp file.
Example:
CRN_BEGIN_MODULE(Meow, AnimalTalk)
public:
Meow();
virtual void Talk();
CRN_END_MODULE(Meow, AnimalTalk)
[in] | classname | the name of the class to register |
[in] | categoryname | the name of the interface (abstract base class of classname) |
Definition at line 232 of file CRNModule.h.
#define CRN_MODULE_ENTRY_POINT | ( | category | ) | crn_module_get_##category |
Internal.
Definition at line 177 of file CRNModule.h.
#define CRN_MODULE_ENTRY_POINT_AS_STRING | ( | category | ) | "crn_module_get_"#category |
Internal.
Definition at line 182 of file CRNModule.h.