Given the following JSON:
{
\"someKey\":\"someValue\",
\"otherKey\":\"otherValue\",
\"features\":[
\"feature1\",
\"feature2\",
\"f
I don't think you can map an array of strings into a ManagedObject like that. However, since Feature only has one name
property you could just store it as an array into your MyTopLevelObject
. You can do that by adding a features
property to MyTopLevelObject
in your datamodel with the type Transformable
. RestKit will automatically parse the features a NSArray with NSStrings. You can then get the features as following:
MyTopLevelObject *topLevelObject = ... // get the object from the persistent store
NSArray *features = (NSArray*)topLevelObject.features; // this will contain the features as NSString objects