-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCurrencyRate.cs
35 lines (28 loc) · 893 Bytes
/
CurrencyRate.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Newtonsoft.Json;
namespace CurrencyLib
{
[JsonObject(MemberSerialization = MemberSerialization.OptIn)]
public class CurrencyRate
{
[JsonProperty(PropertyName = "r030")]
public int r030 { get; set; }
[JsonProperty(PropertyName = "txt")]
public string txt { get; set; }
[JsonProperty(PropertyName = "rate")]
public float rate { get; set; }
[JsonProperty(PropertyName = "cc")]
public string cc { get; set; }
[JsonProperty(PropertyName = "exchangedate")]
public string exchangedate { get; set; }
public string[] ToStringArray()
{
string[] arr = new string[] { r030.ToString(), txt, rate.ToString(), cc };
return arr;
}
}
}