Answer the question
In order to leave comments, you need to log in
How to form complex json in android (java)?
Need to collect json in android app. Collecting a jason like this is not a problem:
{listSettings: {"namePar":"City", "znachPar":["city_name"]} , then there will be other parameters}.
Here you can clearly see from the brackets that json goes, json is nested in it and then an array of city names.
BUT
I need that instead of the nested (second) json there would also be an array, in general, like this:
{listSettings: ["namePar":"City", "znachPar":["city_name"]] , then what will be repeated in the first square brackets, but with different parameters}.
I thought, of course, to make this internal large array through JSONArray, but judging by its methods, this will not work.
I'm asking for some help any ideas and suggestions. Thank you all in advance.
Answer the question
In order to leave comments, you need to log in
listSettings: ["namePar":"City", "znachPar":["city_name"]]
listSettings: [ { "namePar" : "City", "znachPar" : "название_города" }, {...}, {...} ]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question