GBIvarData Class Reference
Inherits from | GBModelBase : NSObject |
Declared in | GBIvarData.h GBIvarData.m |
Tasks
Initialization & disposal
-
+ ivarDataWithComponents:
Returns autoreleased instance of the ivar data from given array of components. -
– initWithDataFromComponents:
Initializes the ivar data from given array of components.
Ivar data
-
nameOfIvar
The name of the ivar. property -
ivarTypes
The array of all ivar type tokens in the order of parsing. property
Other Methods
-
– mergeDataFromObject:
Merges all data from the given object.
Properties
Class Methods
ivarDataWithComponents:
Returns autoreleased instance of the ivar data from given array of components.
+ (id)ivarDataWithComponents:(NSArray *)components
Parameters
- components
- Components array to setup the data from.
Return Value
Returns initialized instance.
Discussion
Components array should contain all ivar type tokens and ivar name as the last entry. Types are copied to ivarTypes
property and name to ivarName
property.
Exceptions
- NSException
- Thrown if the given array of components is
nil
or has only one entry.
Declared In
GBIvarData.h
Instance Methods
initWithDataFromComponents:
Initializes the ivar data from given array of components.
- (id)initWithDataFromComponents:(NSArray *)components
Parameters
- components
- Components array to setup the data from.
Return Value
Returns initialized instance.
Discussion
Components array should contain all ivar type tokens and ivar name as the last entry. Types are copied to ivarTypes
property and name to ivarName
property.
Exceptions
- NSException
- Thrown if the given array of components is
nil
or has only one entry.
Declared In
GBIvarData.h
mergeDataFromObject:
Merges all data from the given object.
- (void)mergeDataFromObject:(id)source
Parameters
- source
- Source object to merge from.
Discussion
Source object is left unchanged. If the same object is passed in, nothing happens. Subclasses should override and add their own specifics, however they should send super object the message as well! Here's overriden method example:
- (void)mergeDataFromObject:(GBModelBase *)source { // source data validation here... [super mergeDataFromObject:source]; // merge custom data here... }
Declared In
GBModelBase.h@71 -> GBIvarData.m