Documentation ¶
Index ¶
- type APIInfo
- type Area
- type Client
- type ClientResult
- type DatetimeRange
- type FourDayWeatherForecast
- type FourDayWeatherForecastOptions
- type FourDayWeatherForecastResult
- type FourDayWeatherForecastResultItem
- type GeneralTwentyFourHourWeatherForecast
- type Location
- type PM25ReadingIntervals
- type PM25ReadingIntervalsGraphQL
- type PM25ReadingRegions
- type PM25ReadingRegionsGraphQL
- type PM25Readings
- type PM25ReadingsOptions
- type PM25ReadingsResult
- type PM25ReadingsResultGraphQL
- type PM25ReadingsResultItem
- type PM25ReadingsResultItemGraphQL
- type PSIReadingIntervals
- type PSIReadingIntervalsGraphQL
- type PSIReadingRegions
- type PSIReadingRegionsGraphQL
- type PSIReadings
- type PSIReadingsOptions
- type PSIReadingsResult
- type PSIReadingsResultGraphQL
- type PSIReadingsResultItem
- type PSIReadingsResultItemGraphQL
- type RegionWeatherForecast
- type RelativeHumidity
- type Speed
- type TaxiAvailabilityOptions
- type TaxiAvailabilityResult
- type TaxiAvailabilityResultGraphQL
- type TaxiAvailabilityResultItem
- type TaxiAvailabilityResultProperties
- type Temperature
- type TrafficImageCamera
- type TrafficImageMetadata
- type TrafficImagesOptions
- type TrafficImagesResult
- type TrafficImagesResultItem
- type TwentyFourHourWeatherForecast
- type TwentyFourHourWeatherForecastOptions
- type TwentyFourHourWeatherForecastResult
- type TwentyFourHourWeatherForecastResultItem
- type TwoHourWeatherForecast
- type TwoHourWeatherForecastGraphQL
- type TwoHourWeatherForecastOptions
- type TwoHourWeatherForecastResult
- type TwoHourWeatherForecastResultGraphQL
- type TwoHourWeatherForecastResultItem
- type TwoHourWeatherForecastResultItemGraphQL
- type UVIndexOptions
- type UVIndexReading
- type UVIndexReadingsResult
- type UVIndexReadingsResultItem
- type Wind
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { APIKey string // contains filtered or unexported fields }
Client is a special HTTP client that batches HTTP requests for the same URL, returning requests through channels
func GetClientFromContext ¶
func (*Client) Get ¶
func (c *Client) Get(url string, target interface{}) chan ClientResult
Get allows user to make a /GET HTTP request, getting it through a channel.
type ClientResult ¶
type ClientResult struct { Body interface{} Err error }
ClientResult contains the result from the HTTP request from Client
type DatetimeRange ¶
type FourDayWeatherForecast ¶
type FourDayWeatherForecast struct { Timestamp string `json:"timestamp,omitempty"` Wind Wind `json:"wind,omitempty"` Forecast string `json:"forecast,omitempty"` RelativeHumidity RelativeHumidity `json:"relative_humidity,omitempty"` Date string `json:"date,omitempty"` Temperature Temperature `json:"temperature,omitempty"` }
type FourDayWeatherForecastResult ¶
type FourDayWeatherForecastResult struct { APIInfo APIInfo `json:"api_info,omitempty"` Items []FourDayWeatherForecastResultItem `json:"items,omitempty"` }
func (*FourDayWeatherForecastResult) ToGraphQL ¶
func (resp *FourDayWeatherForecastResult) ToGraphQL() interface{}
type FourDayWeatherForecastResultItem ¶
type FourDayWeatherForecastResultItem struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` Forecasts []FourDayWeatherForecast `json:"forecasts,omitempty"` }
type GeneralTwentyFourHourWeatherForecast ¶
type GeneralTwentyFourHourWeatherForecast struct { Forecast string `json:"forecast,omitempty"` RelativeHumidity RelativeHumidity `json:"relative_humidity,omitempty"` Temperature Temperature `json:"temperature,omitempty"` Wind Wind `json:"wind,omitempty"` }
type PM25ReadingIntervals ¶
type PM25ReadingIntervals struct {
PM25OneHourly PM25ReadingRegions `json:"pm25_one_hourly,omitempty"`
}
type PM25ReadingIntervalsGraphQL ¶
type PM25ReadingIntervalsGraphQL struct {
PM25OneHourly PM25ReadingRegionsGraphQL `json:"pm25_one_hourly,omitempty"`
}
type PM25ReadingRegions ¶
type PM25ReadingRegionsGraphQL ¶
type PM25ReadingRegionsGraphQL struct { South PM25Readings `json:"south,omitempty"` North PM25Readings `json:"north,omitempty"` East PM25Readings `json:"east,omitempty"` Central PM25Readings `json:"central,omitempty"` West PM25Readings `json:"west,omitempty"` }
type PM25Readings ¶
type PM25ReadingsOptions ¶
type PM25ReadingsResult ¶
type PM25ReadingsResult struct { APIInfo APIInfo `json:"api_info,omitempty"` RegionMetadata []Area `json:"region_metadata,omitempty"` Items []PM25ReadingsResultItem `json:"items,omitempty"` }
func (*PM25ReadingsResult) AreaByName ¶
func (resp *PM25ReadingsResult) AreaByName(name string) Area
func (*PM25ReadingsResult) ToGraphQL ¶
func (resp *PM25ReadingsResult) ToGraphQL() interface{}
type PM25ReadingsResultGraphQL ¶
type PM25ReadingsResultGraphQL struct { APIInfo APIInfo `json:"api_info,omitempty"` Items []PM25ReadingsResultItemGraphQL `json:"items,omitempty"` }
type PM25ReadingsResultItem ¶
type PM25ReadingsResultItem struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` Readings PM25ReadingIntervals `json:"readings,omitempty"` }
type PM25ReadingsResultItemGraphQL ¶
type PM25ReadingsResultItemGraphQL struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` Readings PM25ReadingIntervalsGraphQL `json:"readings,omitempty"` }
type PSIReadingIntervals ¶
type PSIReadingIntervals struct { PSITwentyFourHourly PSIReadingRegions `json:"psi_twenty_four_hourly,omitempty"` PM10TwentyFourHourly PSIReadingRegions `json:"pm10_twenty_four_hourly,omitempty"` PM10SubIndex PSIReadingRegions `json:"pm10_sub_index,omitempty"` PM25TwentyFourHourly PSIReadingRegions `json:"pm25_twenty_four_hourly,omitempty"` PSIThreeHourly PSIReadingRegions `json:"psi_three_hourly,omitempty"` SO2TwentyFourHourly PSIReadingRegions `json:"so2_twenty_four_hourly,omitempty"` O3SubIndex PSIReadingRegions `json:"o3_sub_index,omitempty"` NO2OneHourMax PSIReadingRegions `json:"no2_one_hour_max,omitempty"` SO2SubIndex PSIReadingRegions `json:"so2_sub_index,omitempty"` PM2SubIndex PSIReadingRegions `json:"pm25_sub_index,omitempty"` COEightHourMax PSIReadingRegions `json:"co_eight_hour_max,omitempty"` COSubIndex PSIReadingRegions `json:"co_sub_index,omitempty"` O3EightHourMax PSIReadingRegions `json:"o3_eight_hour_max,omitempty"` }
type PSIReadingIntervalsGraphQL ¶
type PSIReadingIntervalsGraphQL struct { PSITwentyFourHourly PSIReadingRegionsGraphQL `json:"psi_twenty_four_hourly,omitempty"` PM10TwentyFourHourly PSIReadingRegionsGraphQL `json:"pm10_twenty_four_hourly,omitempty"` PM10SubIndex PSIReadingRegionsGraphQL `json:"pm10_sub_index,omitempty"` PM25TwentyFourHourly PSIReadingRegionsGraphQL `json:"pm25_twenty_four_hourly,omitempty"` PSIThreeHourly PSIReadingRegionsGraphQL `json:"psi_three_hourly,omitempty"` SO2TwentyFourHourly PSIReadingRegionsGraphQL `json:"so2_twenty_four_hourly,omitempty"` O3SubIndex PSIReadingRegionsGraphQL `json:"o3_sub_index,omitempty"` NO2OneHourMax PSIReadingRegionsGraphQL `json:"no2_one_hour_max,omitempty"` SO2SubIndex PSIReadingRegionsGraphQL `json:"so2_sub_index,omitempty"` PM2SubIndex PSIReadingRegionsGraphQL `json:"pm25_sub_index,omitempty"` COEightHourMax PSIReadingRegionsGraphQL `json:"co_eight_hour_max,omitempty"` COSubIndex PSIReadingRegionsGraphQL `json:"co_sub_index,omitempty"` O3EightHourMax PSIReadingRegionsGraphQL `json:"o3_eight_hour_max,omitempty"` }
type PSIReadingRegions ¶
type PSIReadingRegionsGraphQL ¶
type PSIReadingRegionsGraphQL struct { National PSIReadings `json:"national,omitempty"` South PSIReadings `json:"south,omitempty"` North PSIReadings `json:"north,omitempty"` East PSIReadings `json:"east,omitempty"` Central PSIReadings `json:"central,omitempty"` West PSIReadings `json:"west,omitempty"` }
type PSIReadings ¶
type PSIReadingsOptions ¶
type PSIReadingsResult ¶
type PSIReadingsResult struct { APIInfo APIInfo `json:"api_info,omitempty"` RegionMetadata []Area `json:"region_metadata,omitempty"` Items []PSIReadingsResultItem `json:"items,omitempty"` }
func (*PSIReadingsResult) AreaByName ¶
func (resp *PSIReadingsResult) AreaByName(name string) Area
func (*PSIReadingsResult) ToGraphQL ¶
func (resp *PSIReadingsResult) ToGraphQL() interface{}
type PSIReadingsResultGraphQL ¶
type PSIReadingsResultGraphQL struct { APIInfo APIInfo `json:"api_info,omitempty"` Items []PSIReadingsResultItemGraphQL `json:"items,omitempty"` }
type PSIReadingsResultItem ¶
type PSIReadingsResultItem struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` Readings PSIReadingIntervals `json:"readings,omitempty"` }
type PSIReadingsResultItemGraphQL ¶
type PSIReadingsResultItemGraphQL struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` Readings PSIReadingIntervalsGraphQL `json:"readings,omitempty"` }
type RegionWeatherForecast ¶
type RelativeHumidity ¶
type TaxiAvailabilityOptions ¶
type TaxiAvailabilityOptions struct {
DateTime string `json:"date_time,omitempy" url:"date_time,omitempy"`
}
type TaxiAvailabilityResult ¶
type TaxiAvailabilityResult struct { Type string `json:"type,omitempty"` CRS interface{} `json:"crs,omitempty"` Features []TaxiAvailabilityResultItem `json:"features,omitempty"` }
TaxiAvailabilityResult interim struct until we model GeoJSON struct
func (*TaxiAvailabilityResult) ToGraphQL ¶
func (resp *TaxiAvailabilityResult) ToGraphQL() interface{}
type TaxiAvailabilityResultItem ¶
type TaxiAvailabilityResultItem struct { Type string `json:"type,omitempty"` Geometry interface{} `json:"geometry,omitempty"` Properties TaxiAvailabilityResultProperties `json:"properties,omitempty"` }
type Temperature ¶
type TrafficImageCamera ¶
type TrafficImageCamera struct { Timestamp string `json:"timestamp,omitempty"` Image string `json:"image,omitempty"` Location Location `json:"location,omitempty"` CameraID int `json:"camera_id,omitempty"` ImageID int `json:"image_id,omitempty"` ImageMetadata TrafficImageMetadata `json:"image_metadata,omitempty"` }
type TrafficImageMetadata ¶
type TrafficImagesOptions ¶
type TrafficImagesOptions struct {
DateTime string `json:"date_time,omitempy" url:"date_time,omitempy"`
}
type TrafficImagesResult ¶
type TrafficImagesResult struct { APIInfo APIInfo `json:"api_info,omitempty"` Items []TrafficImagesResultItem `json:"items,omitempty"` }
func (*TrafficImagesResult) ToGraphQL ¶
func (resp *TrafficImagesResult) ToGraphQL() interface{}
type TrafficImagesResultItem ¶
type TrafficImagesResultItem struct { Timestamp string `json:"timestamp,omitempty"` Cameras []TrafficImageCamera `json:"cameras,omitempty"` }
type TwentyFourHourWeatherForecast ¶
type TwentyFourHourWeatherForecast struct { Time DatetimeRange `json:"time,omitempty"` Regions RegionWeatherForecast `json:"regions,omitempty"` }
type TwentyFourHourWeatherForecastResult ¶
type TwentyFourHourWeatherForecastResult struct { APIInfo APIInfo `json:"api_info,omitempty"` Items []TwentyFourHourWeatherForecastResultItem `json:"items,omitempty"` }
func (*TwentyFourHourWeatherForecastResult) ToGraphQL ¶
func (resp *TwentyFourHourWeatherForecastResult) ToGraphQL() interface{}
type TwentyFourHourWeatherForecastResultItem ¶
type TwentyFourHourWeatherForecastResultItem struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` ValidPeriod DatetimeRange `json:"valid_period,omitempty"` General GeneralTwentyFourHourWeatherForecast `json:"general,omitempty"` Periods []TwentyFourHourWeatherForecast `json:"periods,omitempty"` }
type TwoHourWeatherForecast ¶
type TwoHourWeatherForecastResult ¶
type TwoHourWeatherForecastResult struct { APIInfo APIInfo `json:"api_info,omitempty"` AreaMetadata []Area `json:"area_metadata,omitempty"` Items []TwoHourWeatherForecastResultItem `json:"items,omitempty"` }
func (*TwoHourWeatherForecastResult) AreaByName ¶
func (resp *TwoHourWeatherForecastResult) AreaByName(name string) Area
func (*TwoHourWeatherForecastResult) ToGraphQL ¶
func (resp *TwoHourWeatherForecastResult) ToGraphQL() interface{}
type TwoHourWeatherForecastResultGraphQL ¶
type TwoHourWeatherForecastResultGraphQL struct { APIInfo APIInfo `json:"api_info,omitempty"` Items []TwoHourWeatherForecastResultItemGraphQL `json:"items,omitempty"` }
type TwoHourWeatherForecastResultItem ¶
type TwoHourWeatherForecastResultItem struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` ValidPeriod DatetimeRange `json:"valid_period,omitempty"` Forecasts []TwoHourWeatherForecast `json:"forecasts,omitempty"` }
type TwoHourWeatherForecastResultItemGraphQL ¶
type TwoHourWeatherForecastResultItemGraphQL struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` ValidPeriod DatetimeRange `json:"valid_period,omitempty"` Forecasts []TwoHourWeatherForecastGraphQL `json:"forecasts,omitempty"` }
type UVIndexOptions ¶
type UVIndexReading ¶
type UVIndexReadingsResult ¶
type UVIndexReadingsResult struct { APIInfo APIInfo `json:"api_info,omitempty"` Items []UVIndexReadingsResultItem `json:"items,omitempty"` }
func (*UVIndexReadingsResult) ToGraphQL ¶
func (resp *UVIndexReadingsResult) ToGraphQL() interface{}
type UVIndexReadingsResultItem ¶
type UVIndexReadingsResultItem struct { UpdateTimestamp string `json:"update_timestamp,omitempty"` Timestamp string `json:"timestamp,omitempty"` Index []UVIndexReading `json:"index,omitempty"` }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.