I am not too old in android development, so sorry if the question is so stupid. I have recently learnt about JSON data format and downloading JSON data arrays and objects in my app? but in all tutorials I have seen the instructor creates a JSON file him self and upload it online then download it from the android app(which he is creating the tutorial about). I Know that it is faster than xml it downloading and rendering but who to know that the data I am downloading is in JSON or not? who specifies that? Thank u in advance.
The server define the response and the client (mobile app) should be prepared to receive the data in the specified content type from the server.
JSON content type example :
Content-type: application/json
Not sure what your question is really about, but some remarks:
Hoping it will help you :)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.