using System; using System.Globalization; namespace Buypeeb { class Listing { public string url; public string id; public string name; public int price; public int win_price; public string original_name; public bool favourite; // start_date, end_date public int bids; public bool auto_extension; public Listing(string url, string id, string name) { this.url = url; this.id = id; this.name = name; } public void Update() { // use fake values for now var rnd = new Random(); this.price = rnd.Next(100, 5000); this.bids = rnd.Next(0, 15); this.name = "testing"; this.original_name = "testing"; } public string PriceAUD() { double aud = this.price / 75.0; return $"${aud:f2}"; } public string PriceJPY() { return $"¥{this.price}"; } } }