libGimbal 0.1.0
C17-Based Extended Standard Library and Cross-Language Runtime Framework
|
Go to the source code of this file.
Data Structures | |
struct | GblObjectClass |
class | GblObject |
Macros | |
#define | GBL_NEW(...) |
#define | GBL_PLACEMENT_NEW(...) |
Type System | |
Type UUID and Cast operators | |
#define | GBL_OBJECT_TYPE |
#define | GBL_OBJECT(self) |
#define | GBL_OBJECT_CLASS(klass) |
#define | GBL_OBJECT_GET_CLASS(self) |
GblObject structure and related functions.
This file contains the type definitions and API for GblObject and GblObjectClass. This is the instantiable type which provides the OO meat of the instantiable types– such as properties, hierarchial relationships, event management, generic construction, named instances, etc.
Definition in file gimbal_object.h.
#define GBL_OBJECT_TYPE |
GblType UUID for GblObject.
Definition at line 34 of file gimbal_object.h.
#define GBL_OBJECT | ( | self | ) |
Casts a GblInstance to a GblObject.
Definition at line 35 of file gimbal_object.h.
#define GBL_OBJECT_CLASS | ( | klass | ) |
Casts a GblClass to a GblObjectClass.
Definition at line 36 of file gimbal_object.h.
#define GBL_OBJECT_GET_CLASS | ( | self | ) |
Gets a GblObjectClass from a GblInstance.
Definition at line 37 of file gimbal_object.h.
#define GBL_NEW | ( | ... | ) |
DSL macro used to heap-construct a GblObject-derived type.
It takes the struct name followed by an optional list of property KV pairs.
Definition at line 43 of file gimbal_object.h.
#define GBL_PLACEMENT_NEW | ( | ... | ) |
DSL macro used to placement-construct a GblObject-derived type It takes the struct name followed by an optional list of property KV pairs.
Definition at line 47 of file gimbal_object.h.
Creates an object-derived type on the heap, intializing it with a NULL-terminated K,V pair listing of properties.
Variant of GblObject_create(), where the object is created with an extended size.
GBL_RESULT GblObject_construct | ( | GblObject * | pSelf, |
GblType | type, | ||
... | |||
) |
Constructs an object-derived type in-place, initializing it with a NULL-terminated K,V pair listing of properties.
GblObject * GblObject_createWithClass | ( | GblObjectClass * | pClass, |
... | |||
) |
Creates an object-derived type on the heap, with the given class, initializing it with a NULL-terminated K,V pair property list.
GblObject * GblObject_createExtWithClass | ( | GblObjectClass * | pClass, |
size_t | size, | ||
... | |||
) |
Variant of GblObject_createWithClass(), where the object is created with an extended size.
GBL_RESULT GblObject_constructWithClass | ( | GblObject * | pSelf, |
GblObjectClass * | pClass, | ||
... | |||
) |
Constructs an object-derived type in-place, with the given class, initializing it with a NULL-terminated K,V pair property list.
Variant of GblObject_create(), where the property list is provided as a va_list pointer.
Variant of GblObject_createVaList(), where the object is created with an extended size.
GBL_RESULT GblObject_constructVaList | ( | GblObject * | pSelf, |
GblType | type, | ||
va_list * | pList | ||
) |
Variant of GblObject_construct(), where the property list is provided as a va_list pointer.
GblObject * GblObject_createVaListWithClass | ( | GblObjectClass * | pClass, |
va_list * | pList | ||
) |
Variant of GblObject_createWithClass(), where the property list is provided as a va_list pointer.
GblObject * GblObject_createExtVaListWithClass | ( | GblObjectClass * | pClass, |
size_t | size, | ||
va_list * | pList | ||
) |
Variant of GblObject_createVaListWithClass(), where the object is allocated with an extended size.
GBL_RESULT GblObject_constructVaListWithClass | ( | GblObject * | pSelf, |
GblObjectClass * | pClass, | ||
va_list * | pList | ||
) |
Variant of GblObjecT_constructWithClass(), where the property list is provided as a va_list pointer.
GblObject * GblObject_createVariants | ( | GblType | type, |
size_t | propertyCount, | ||
const char * | pNames[], | ||
GblVariant * | pValues | ||
) |
Creates an object-derived type on the heap, initializing it with an array of property values and a corresponding array of names.
GblObject * GblObject_createVariantsExt | ( | GblType | type, |
size_t | size, | ||
size_t | propertyCount, | ||
const char * | pNames[], | ||
GblVariant * | pValues | ||
) |
Variant of GblObject_createVariants(), where the object is allocated with an extended size.
GBL_RESULT GblObject_constructVariants | ( | GblObject * | pSelf, |
GblType | type, | ||
size_t | propertyCount, | ||
const char * | pNames[], | ||
GblVariant * | pValues | ||
) |
Creates an object-derived type in-place, initiailzing it with an array of property values and a corresponding array of names.
GblObject * GblObject_createVariantsWithClass | ( | GblObjectClass * | pClass, |
size_t | propertyCount, | ||
const char * | pNames[], | ||
GblVariant * | pValues | ||
) |
Variant of GblObject_createVariants(), where the object is constructed with a weak reference to the given class.
GblObject * GblObject_createVariantsExtWithClass | ( | GblObjectClass * | pClass, |
size_t | size, | ||
size_t | propertyCount, | ||
const char * | pNames[], | ||
GblVariant * | pValues | ||
) |
Variant of GblObject_createVariantsWithClass(), where the object is allocated with an extended size.
GBL_RESULT GblObject_constructVariantsWithClass | ( | GblObject * | pSelf, |
GblObjectClass * | pClass, | ||
size_t | propertyCount, | ||
const char * | pNames[], | ||
GblVariant * | pValues | ||
) |
Variant of GblObject_constructVariants(), where the object is constructed with a weak reference to the given class.