when using the objSet method it and try to add data to a nested JSONObject it overwrites all other data.
For example, if you have this JSON file:
"User 1": {
"name": "John",
"age": 27,
"employer": "meta"
}
and you want to add another attribute to User 1 and you use the setObj method it will overwrite all other attributes and only saves the new one that you want.
when using the
objSetmethod it and try to add data to a nested JSONObject it overwrites all other data.For example, if you have this JSON file:
and you want to add another attribute to
User 1and you use thesetObjmethod it will overwrite all other attributes and only saves the new one that you want.