C# 命名空间Kendo.Mvc.Infrastructure中的AggregateResult-从Json中取消序列化
我使用命名空间Kendo.Mvc.Infrastructure中的类:C# 命名空间Kendo.Mvc.Infrastructure中的AggregateResult-从Json中取消序列化,c#,json,kendo-asp.net-mvc,C#,Json,Kendo Asp.net Mvc,我使用命名空间Kendo.Mvc.Infrastructure中的类: public class AggregateResult { public AggregateResult(object value, AggregateFunction function); public AggregateResult(object value, int count, AggregateFunction function); public object Value { g
public class AggregateResult
{
public AggregateResult(object value, AggregateFunction function);
public AggregateResult(object value, int count, AggregateFunction function);
public object Value { get; }
public string Member { get; }
public object FormattedValue { get; }
public int ItemCount { get; set; }
public string Caption { get; }
public string FunctionName { get; }
public string AggregateMethodName { get; }
public string Format(string format);
public override string ToString();
}
我从服务器上得到一个json响应:
{“NewQty”:{“sum”:0},“TotalQty”:{“sum”:0}}
我需要编写一个解析器函数来获取AggregateResult类型的对象,以便在服务端填充它并将其发送回视图。
NewAquantity映射为成员,值设置为quantity,sum-AggregateMethodName
很遗憾,Newtonsoft.JsonJsonConvert.DeserializeObject方法无法执行此操作。非常感谢你的帮助