在我的应用程序中,我使用 facebook sdk for android 接收来自 Facebook 的通知。但是方法返回的数据response.toString()
是json格式的。
我需要知道如何将其转换为简单的人类可读格式,以便可以使用它们在文本字段中查看?
这就是我从图形资源管理器中得到的。必需的字符串是“标题”
{
"id": "10000115768434",
"name": "Nauman Aslam",
"notifications": {
"data": [
{
"id": "notif_10000357346818423_6543370",
"from": {
"name": "Muhammad Asad Iqbal",
"id": "56342467433"
},
"to": {
"name": "Nauman Aslam",
"id": "324545436818423"
},
"created_time": "2014-03-28T20:09:02+0000",
"updated_time": "2014-03-28T20:16:05+0000",
"title": "Muhammad Asad Iqbal and Smat Kazmi also commented on Muhammad Asad Iqbal's photo.",
"link": "http://www.facebook.com/photo.php?fbid=4040070417111&se",
"application": {
"name": "Photos",
"id": "54635732"
},
"unread": 1
},