コード例 #1
0
        private async Task GetSensors()
        {
            WriteLine($"Testing GET '{_route}/{SensorApi.Path}'.");

            ICollection <Sensor> sensors = await _sensorApi.Get <Sensor>();

            WriteLine($"Got {sensors.Count} Sensors:");
            foreach (Sensor sensor in sensors)
            {
                WriteLine(sensor.GetPrintString());
            }
            WriteLine();
        }
コード例 #2
0
        private async Task GetSensors()
        {
            WriteLine($"Testing GET \"{Route}{Sensors.Route}\"");

            ICollection <Sensor> sensors = await Sensors.Get <Sensor>();

            WriteLine($"Got {sensors.Count} Sensors:");
            foreach (Sensor sensor in sensors)
            {
                WriteLine(sensor.GetPrintString());
            }
            WriteLine();
        }