26 lines
554 B
C#
26 lines
554 B
C#
using System;
|
|
using Newtonsoft.Json.Linq;
|
|
using System.Threading;
|
|
using Newtonsoft.Json.Serialization;
|
|
using Newtonsoft.Json;
|
|
using System.Collections.Generic;
|
|
|
|
namespace sharp.jsonrpc
|
|
{
|
|
public class Response {
|
|
public string jsonrpc { get; set; }
|
|
public string id { get; set; }
|
|
public Dictionary<string, JToken> result { get; set; }
|
|
public string error { get; set; }
|
|
|
|
public Response(string source){
|
|
JsonConvert.PopulateObject(source,this);
|
|
}
|
|
|
|
public bool Success(){
|
|
return result["status"].ToString().Equals("OK");
|
|
}
|
|
|
|
}
|
|
}
|