コード例 #1
0
        public string Get()
        {
            var connect  = new ConnectNOAA();
            var response = connect.Request("https://www.ncdc.noaa.gov/cdo-web/api/v2/stations?locationid=ZIP%3A33139&limit=20&includemetadata=false&sortfield=name&sortorder=asc");

            return(response);
        }
コード例 #2
0
        public string Get(StationsParameters parameters, string stationid = null)
        {
            var connect  = new ConnectNOAA();
            var jsonData = "";

            if (!String.IsNullOrEmpty(stationid))
            {
                jsonData = connect.Request($"{new StationsParameters().EndPoint}/{stationid}");
            }
            else
            {
                jsonData = parameters.prepareData(connect);
            }

            //objectData.PrintToConsole();
            return(jsonData);
        }