NSObject(ETFramework) Category Reference
| Declared in | ETObject.h |
Overview
NSObject (ETFramework) is a helper class that provides extra methods for better and easiest handling of NSObject.
Attaching extra data
- Provides helper methods to attach and retrieve objects to specific
NSObject.
NSDictionary initialization and manipulation
- Provides some extra methods to manipulate
NSDictionaryobjects.
Helper methods
- Also provides some extra methods available as
Cfunctions.
Instance Methods
attachUserInfo:
Dynamically attach an object to a NSObject instance using the runtime framework with a predefined key.
- (void)attachUserInfo:(id)userInfoParameters
- userInfo
The object that will be ‘linked’ to the
NSObjectinstance.
Declared In
ETObject.hattachUserInfo:forKey:
Dynamically attach an object to a NSObject instance using the runtime framework and links it using the provided key.
- (void)attachUserInfo:(id)userInfo forKey:(char const *)keyParameters
- userInfo
The object that will be ‘linked’ to the
NSObjectinstance.
- key
The custom key that will be used to attach the object to the
NSObjectinstance.
Declared In
ETObject.hinitFromDictionary:
Initializes an NSObject using the provided NSDictionary object and KVC.
- (id)initFromDictionary:(NSDictionary *)dictionaryParameters
- dictionary
The
NSDictionaryobject that will be used to ‘feed’ theNSObjectproperties.
Return Value
An initialized NSObject instance with the properties set to the matching keys/fields provided by the defined NSDictionary.
Declared In
ETObject.hinitFromDictionary:dateFormatter:
Initializes an NSObject using the provided NSDictionary object and KVC with the provided NSDateFormatter.
- (id)initFromDictionary:(NSDictionary *)dictionary dateFormatter:(NSDateFormatter *)dateFormatterParameters
- dictionary
The
NSDictionaryobject that will be used to ‘feed’ theNSObjectproperties.
- dateFormatter
The
NSDateFormatterthat will be used to format all theNSDateobjects found on the providedNSDictionary.
Return Value
An initialized NSObject instance with the properties set to the matching keys/fields provided by the defined NSDictionary.
Declared In
ETObject.hupdateDataWithDictionary:
Updates an NSObject using the provided NSDictionary object and KVC.
- (id)updateDataWithDictionary:(NSDictionary *)dictionaryParameters
- dictionary
The
NSDictionaryobject that will be used to ‘feed’ theNSObjectproperties.
Return Value
The NSObject instance with its properties set to the matching keys/fields provided by the defined NSDictionary.
Declared In
ETObject.hupdateDataWithDictionary:dateFormatter:
Updates an NSObject using the provided NSDictionary object and KVC with the provided NSDateFormatter.
- (id)updateDataWithDictionary:(NSDictionary *)dictionary dateFormatter:(NSDateFormatter *)dateFormatterParameters
- dictionary
The
NSDictionaryobject that will be used to ‘feed’ theNSObjectproperties.
- dateFormatter
The
NSDateFormatterthat will be used to format all theNSDateobjects found on the providedNSDictionary.
Return Value
The NSObject instance with its properties set to the matching keys/fields provided by the defined NSDictionary.
Declared In
ETObject.huserInfo
Retrieves the object attached to the NSObject instance ‘linked’ with the predefined key.
- (id)userInfoReturn Value
The object attached to the NSObject instance ‘linked’ with the predefined key.
Declared In
ETObject.huserInfoForKey:
Retrieves the object attached to the NSObject instance using the provided key.
- (id)userInfoForKey:(char const *)keyParameters
- key
The custom key that will be used to try and retrieve a ‘linked’ object with this
NSObjectinstance.
Return Value
The object attached to the NSObject instance ‘linked’ with the provided key.
Declared In
ETObject.h