以下是我从API获得的Json数据。我正在尝试从中构建一个剑道图表。是否有一种很好的方法来访问值(350,90)并绑定到图表。
// Modified C++ code
// Arrays are reference types in .NET framework so I don't need to pass a pointer.
public static byte HexToByte(byte[] buffer)
{
return HexToNibble((byte)((buffer[0] * 0x10) + HexToNibble(buffer[1])));
}
private static byte HexToNibble(byte HexChar)
{
if ((HexChar >= 48) && (HexChar <= 57))
return (byte)(HexChar - 48);
if ((HexChar >= 65) && (HexChar <= 70))
return (byte)(HexChar - 55);
if ((HexChar >= 97) && (HexChar <= 102))
return (byte)(HexChar - 87);
return 0;
}
checksum = 0;
for (int j = 0; j < count; j++)
checksum += utils.HexToByte(buffer[2 + i * 2]); // can't pass this argument ??? WHY CAN I DO THIS IN C++??
到目前为止代码,但我正试图让它变得动态
"Issues": [
{
"Id": null,
"Key": null,
"Values": [
{
"Key": "Display Name",
"Value": "Rya"
},
{
"Key": "UserName",
"Value": "RH"
},
{
"Key": "Count",
"Value": "350"
}
]
},
{
"Id": null,
"Key": null,
"Values": [
{
"Key": "Display Name",
"Value": "Mike"
},
{
"Key": "UserName",
"Value": "ML"
},
{
"Key": "Count",
"Value": "90"
}
]
}
],