In fact, this kind of problem belongs to the problem of peeling garlic. . It peeled off with some patience. The whole thing is an array, right?
items = [@item0,@teim1,@item2, @item3];
Look at the attributes of item0 and continue peeling the garlic
NSDictionary *item = items[0];
Look at the attributes of music under item0 and continue peeling the garlic
NSArray *musics = item[@"musics"]
Then continue to peel the garlic.... For this type of question, just peel the garlic based on the attributes,
But I generally don’t recommend this method of playing, it is not intuitive and easy to make mistakes. Modify the data structure and the whole person will be sb. Peel the garlic again.
So you can take a look at JSONModel. If you don’t understand it very well, you can also ask me.
https://github.com/icanzilb/JSONModel
A project to model data, similar to GSON in Java. Although the efficiency is average, it is very easy to use, much easier to use than those with high efficiency.
In fact, this kind of problem belongs to the problem of peeling garlic. . It peeled off with some patience.
Look at the attributes of item0 and continue peeling the garlicThe whole thing is an array, right?
But I generally don’t recommend this method of playing, it is not intuitive and easy to make mistakes. Modify the data structure and the whole person will be sb. Peel the garlic again.
So you can take a look at JSONModel. If you don’t understand it very well, you can also ask me.Get the array with key=music in item0
Then get the dictionary based on index from this array
Then get it from the dictionary based on key