jsonで次の応答がありますが、解析方法がわかりません
[{"WordArray":[{"Id":11,"Word1":"ODDER","Category":"Dyr","Differculty":1,"Language":"Danish"},{"Id":225,"Word1":"PRAG","Category":"International by","Differculty":1,"Language":"Danish"}]},{"WordArray":[{"Id":3,"Word1":"TIGER","Category":"Dyr","Differculty":1,"Language":"Danish"},{"Id":154,"Word1":"BOLLE","Category":"Mad og drikke","Differculty":1,"Language":"Danish"}]},
{"WordArray":[{"Id":3,"Word1":"TIGER","Category":"Dyr","Differculty":1,"Language":"Danish"},{"Id":147,"Word1":"PIZZA","Category":"Mad og drikke","Differculty":1,"Language":"Danish"}]}]
私は運がなくて次のことを試しました
NSMutableArray* json = [NSJSONSerialization JSONObjectWithData:responseData options:kNilOptions error:&error];
NSMutableArray * roundWords = [[NSMutableArray alloc]retain ];
roundWords = [json objectAtIndex:i];
jsonには私の3つの「WordArray」が含まれていますが、どのように進めるかがわかりません。たとえば、の各項目を反復処理して値WordArray
をNSLogするにはどうすればよいWord1
ですか?
ありがとう!