Exemplo n.º 1
0
        public static async Task <IEnumerable <ShopSensorEvent> > GetTodayEvents()
        {
            var response = await http.GetAsync("api/ShopSensor?daysSince=1");

            var content = await response.Content.ReadAsStringAsync();

            return(ShopSensorEvent.FromJson(content));
        }
Exemplo n.º 2
0
 public async Task <IEnumerable <ShopSensorEvent> > ReadTodayEvents()
 {
     return(ShopSensorEvent.FromJson(
                await(await http.GetAsync("api/ShopSensor?DaysSince=2"))
                .Content.ReadAsStringAsync()));
 }