I want to recover the values contained in a NSDictionary.
I do this :
MyCommon *pCommon = [MyCommon Singleton];
NSArray *result = pCommon.res; //res is define and retain in common.m. This is the array.
NSDictionary *dataItem = [result objectAtIndex:????];
i don’t know what i can put to replace the ????
Thanks
Unlike some other languages, Objective-C makes a distinction between Arrays and Dictionaries.
An array is a collection, indexed by number. A dictionary is a collection indexed by objects (commonly strings, but can be other types).
On top of that, Objective-C makes a distinctions between mutable and immutable arrays and dictionaries.
NSArrayandNSDictionarycannot be modified after they are created. If you need to add objects to your collection, useNSMutableArrayandNSMutableDictionaryinstead.