コード例 #1
0
        public LatLongsToDistanceResults GetLatLongsToDistance(LatLongsToDistance model)
        {
            IApiConnector <Models.OutputModels.LatLongsToDistanceResults, ApiError> connector = new ApiConnector <Models.OutputModels.LatLongsToDistanceResults, ApiError>();

            var requestUrl = _apiConnectionString
                             .AppendPathSegment("LatLongsToDistance")
                             .SetQueryParams(new
            {
                lat1 = model.lat1,
                lon1 = model.lon1,
                lat2 = model.lat2,
                lon2 = model.lon2
            });

            return(connector.GetRequest(requestUrl, checkfield, "Basic", _credentials).Responce);
        }
コード例 #2
0
 public JsonResult latLongsToDistance(LatLongsToDistance model)
 {
     return(Json(_flightAwareAPI.GetLatLongsToDistance(model), JsonRequestBehavior.AllowGet));
 }