#include "AtxDefs.h"
#include "AtxTypes.h"
#include "AtxInterfaces.h"
#include "AtxProperties.h"
Go to the source code of this file.
Defines | |
| #define | ATX_Module_CreateObject(self, parameters, interface_id, result) |
| Convenience macro for calling the CreateObject method of the ATX_Module interface. | |
| #define | ATX_DEFINE_NULL_MODULE_INSTANCE(_prefix) static ATX_ModuleInstance* const _prefix##ModuleInstance = NULL; |
| #define | ATX_IMPLEMENT_SIMPLE_MODULE_INTERFACE(_refix) |
| #define | ATX_IMPLEMENT_SIMPLE_MODULE_PROPERTIES(_prefix) |
Variables | |
| ATX_Result(* | CreateInstance )(ATX_Module *self, ATX_String parameters, const ATX_InterfaceId *interface_id, ATX_Object *object) |
| #define ATX_IMPLEMENT_SIMPLE_MODULE_INTERFACE | ( | _refix | ) |
Value:
static const ATX_ModuleInterface _prefix##ModuleATX_ModuleInterface = { \ _prefix##Module_GetInterface, \ _prefix##Module_CreateInstance \ };
| #define ATX_IMPLEMENT_SIMPLE_MODULE_PROPERTIES | ( | _prefix | ) |
Value:
ATX_DECLARE_SIMPLE_GET_INTERFACE_IMPLEMENTATION(_prefix##Module) \
ATX_IMPLEMENT_SIMPLE_STATIC_PROPERTIES_INTERFACE(_prefix##Module, \
_prefix##ModuleProperties)
| #define ATX_Module_CreateObject | ( | self, | |||
| parameters, | |||||
| interface_id, | |||||
| result | ) |
Value:
ATX_INTERFACE(object)->CreateObject(self, \ parameters, \ interface_id, \ result)
| ATX_Result(* CreateInstance)(ATX_Module *self, ATX_String parameters, const ATX_InterfaceId *interface_id, ATX_Object *object) |
Interface implemented by objects that create other objects A Module object is responsible for creating object instance of a certain class. Module objects implement the ATX_Module interface, and clients that want to create instances of that module will call the CreateObject method. create an instance of the module that implements a given interface
| self | Pointer to the object on which the method is called | |
| parameters | Generic parameters used for constructing the object | |
| interface_id | Interface ID that the object needs to implement | |
| object | address of an object reference where the created object will be returned if the call succeeds |