class FlightStats::Airport
Attributes
active[RW]
city[RW]
city_code[RW]
classification[RW]
country_code[RW]
country_name[RW]
delay_index_url[RW]
elevation_feet[RW]
faa[RW]
fs[RW]
iata[RW]
icao[RW]
latitude[RW]
local_time[RW]
longitude[RW]
name[RW]
postal_code[RW]
region_name[RW]
state_code[RW]
street1[RW]
time_zone_region_name[RW]
utc_offset_hours[RW]
weather_url[RW]
weather_zone[RW]
Public Class Methods
actives(options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 31 def actives(options = {}) from_response API.get("#{base_path}/active", {}, options), 'airports' end
actives_for_date(year, month, day, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 35 def actives_for_date(year, month, day, options = {}) from_response API.get("#{base_path}/active/#{year}/#{month}/#{day}", {}, options), 'airports' end
all(options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 39 def all(options = {}) from_response API.get("#{base_path}/all", {}, options), 'airports' end
base_path()
click to toggle source
# File lib/flightstats/airport.rb, line 83 def base_path @@base_path end
by_city_code(city_code, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 51 def by_city_code(city_code, options = {}) from_response API.get("#{base_path}/cityCode/#{city_code}", {}, options), 'airports' end
by_country_code(country_code, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 55 def by_country_code(country_code, options = {}) from_response API.get("#{base_path}/countryCode/#{country_code}", {}, options), 'airports' end
by_flight_stats_code(flight_stats_code, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 59 def by_flight_stats_code(flight_stats_code, options = {}) from_response API.get("#{base_path}/fs/#{flight_stats_code}", {}, options), 'airport' end
by_iata_code(iata_code, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 63 def by_iata_code(iata_code, options = {}) from_response API.get("#{base_path}/iata/#{iata_code}", {}, options), 'airports' end
by_iata_code_on_date(iata_code, year, month, day, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 67 def by_iata_code_on_date(iata_code, year, month, day, options = {}) from_response API.get("#{base_path}/iata/#{iata_code}/#{year}/#{month}/#{day}", {}, options), 'airport' end
by_icao_code(icao_code, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 71 def by_icao_code(icao_code, options = {}) from_response API.get("#{base_path}/icao/#{icao_code}", {}, options), 'airports' end
by_icao_code_on_date(icao_code, year, month, day, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 75 def by_icao_code_on_date(icao_code, year, month, day, options = {}) from_response API.get("#{base_path}/icao/#{icao_code}/#{year}/#{month}/#{day}", {}, options), 'airport' end
current(code, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 43 def current(code, options = {}) from_response API.get("#{base_path}/#{code}/today", {}, options), 'airport' end
on_date(code, year, month, day, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 47 def on_date(code, year, month, day, options = {}) from_response API.get("#{base_path}/#{code}/#{year}/#{month}/#{day}", {}, options), 'airport' end
within_radius(longitude, latitude, radius_miles, options = {})
click to toggle source
# File lib/flightstats/airport.rb, line 79 def within_radius(longitude, latitude, radius_miles, options = {}) from_response API.get("#{base_path}/withinRadius/#{longitude}/#{latitude}/#{radius_miles}", {}, options), 'airports' end