私はjsonの文字列を解析するためにiPhoneのjson-frameworkで作業しようとしています。 私は、このメソッドを呼び出しています:JSON検証
NSDictionary *dictionary = [jsonString JSONValue];
私はエラーを取得しています:
"Error Domain=org.brautaset.JSON.ErrorDomain Code=3 \"Object value expected for key:
Options\" UserInfo=0x4b5f390 {NSUnderlyingError=0x4b5f320 \"Expected value while
parsing array\", NSLocalizedDescription=Object value expected for key: Options}"
このJSONバリデータによると、[1]:http://www.jsonlint.com//私のJSONが有効ではありません。しかし、それはそうですか?
{
"Options": [
{
"ID": "7",
"A": "1",
"EAt": new Date(2011,
0,
7,
12,
30,
0),
"Type": "Binary",
}
}
*編集JSON::私のJSON文字列は次のようになります
後にカンマを削除する(まだエラーが表示されます)
{
"Options": [
{
"ID": "7",
"A": "1",
"EAt": new Date(2011,
0,
7,
12,
30,
0),
"Type": "Binary"
}
]
}
バイナリ " – powtac