正在分析JSON(C#)
本文关键字:JSON | 更新日期: 2023-09-27 18:20:37
我有以下文本响应:
Game = [1, "MyGame", {
1: ["Role1", 2],
2: ["Role2", 2],
3: ["Role3", 3],
4: ["Role4", 4]
}, { }];
Players = [
[5, "Player1", 2],
[4, "Player2", 21],
[9, "Player3", 22],
[0, "Player4", 23],
[26, "Player5", 24],
[1, "Player6", 25],
[2, "Player7", 26],
[9, "Player8", 27],
[1, "Player9", 28],
[7, "Player10", 29],
[5, "Player11", 30],
[2, "Player12", 31],
[3, "Player13", 32],
[7, "Player14", 33],
[3, "Player15", 34],
[1, "Player16", 35]
];
我需要解析这个上下文。我该怎么做?我正在使用C#。
尝试使用:System.Web.Helpershttp://msdn.microsoft.com/en-us/library/system.web.helpers.json(v=vs.111).aspx
dynamic data = Json.Decode(json);