Annada Annada - 4 months ago 8
JSON Question

is "NULL" is valid for JSON null value in any of the JSON library used for android

previously json null was handling properly in app. But suddenly app failed to parse son, as it found NULL instead of null. I want to know, if "NULL" is valid null json object, in any of the json library used for android.

N J N J
Answer

Here is some info .

  1. First of all null is keyword in JAVA for indicating object is empty(null).

  2. NULL is not keyword in JAVA

  3. NULL is valid value for string if it is enclosed by "". eg "NULL"

I want to know, if "NULL" is valid null json object, in any of the json library used for android.

Answer is NO.