Zen API
|
#define kAddFrameworkConstructor | ( | SYMBOL, | |
CTOR | |||
) |
Within a type definition, indicates that a type has the specified framework constructor.
Framework constructors are used to construct objects via reflection, and are not inherited. Their scope is limited to specific frameworks (deserialization and cloning) that guarantee constrained usage patterns. Specifically, after default construction, a framework-specific method will always be invoked to complete object initialization (e.g., deserialization method). If this framework-specific method should fail, kObject_Dispose will be called on the partially constructed object to clean up. As such, the only requirement when implementing a default constructor is to sufficiently initialize the object such that it could accept a subsequent framework initialization method, or be disposed.
Framework constructors should be defined with a signature compatible with kFrameworkConstructorFx.
SYMBOL | Type symbol (e.g. kArrayList). |
CTOR | Constructor name (e.g. ConstructFramework). |