When writing code today, the ability to receive JSON data into map pairs is completed.
It's coming in.
{appintroduction=null,
Appscene=null,
Appid= "123",
Callbackurl= "http://zdwssq.picp.net/QiWei/userInfo?corpId= $CORPID $",
Appname= "New 3",
Applogoname= "6d5e965c-80af-4782-9bca-af914099043dicon_6.png",
Appintroimage=null,
Appsuiteid= "Tj8eabd12547d13d3d"
}
The error can ' t cast jsonnull to string null at Map.get ("Appintroduction").
It's strange that it was the string null why it became jsonnull.
Check the data found that Net.sf.json will be judged if value =null will automatically convert null to Jsonnull do not understand why =.=
So just add a judgment.
Object o= Map.get (key);
String str= "";
if (o instanceof jsonnull)
Value= Map.get (key);
Else
.......
If it is an org, JSON returns a string of NULL
Solution of Can ' t cast jsonnull to string null