NSArray as two dimensional array
Can anybody suggest which is the best way for using NSArray as t开发者_StackOverflow社区wo-dimensional array to store data for filtering data based on field.
Thanks in advance
Regards, sathish
you can create an 1. array of arrays, 2. array of dictionaries, 3. array of custom class objects..
In any case you will have to do almost equal amount of work for filtering based on field..
Because you didn't provide any context for your question, is there a reason why you aren't using a 2-dimensional C array to store data? (You can use C primitives, types and structs in Objective-C just fine.) Is there a reason why you need to use NSArray
? (Is it the right tool for the job?)
精彩评论