public static ORDER ReadFromJObject(JObject o) { if (o == null) { return(null); } return(new ORDER() { Pair = BTCECURRENCYPAIRHELPER.FromString(o.Value <string>("pair")), Type = TRADETYPEHELPER.FromString(o.Value <string>("type")), Amount = o.Value <decimal>("amount"), Rate = o.Value <decimal>("rate"), TimestampCreated = o.Value <UInt32>("timestamp_created"), Status = o.Value <int>("status") }); }
public static TRADE ReadFromJObject(JObject o) { if (o == null) { return(null); } return(new TRADE() { Pair = BTCECURRENCYPAIRHELPER.FromString(o.Value <string>("pair")), Type = TRADETYPEHELPER.FromString(o.Value <string>("type")), Amount = o.Value <decimal>("amount"), Rate = o.Value <decimal>("rate"), Timestamp = o.Value <UInt32>("timestamp"), IsYourOrder = o.Value <int>("is_your_order") == 1, OrderId = o.Value <int>("order_id") }); }