Documentation ¶
Index ¶
Constants ¶
View Source
const ( APIKeyFilename = "./.weather-api-key" URLPattern = "http://api.openweathermap.org/data/2.5/weather?%s&units=imperial&APPID=%s" )
Variables ¶
This section is empty.
Functions ¶
func ComposeRequestURI ¶ added in v0.0.3
ComposeRequestURI takes API key, request type t, parameter argument p and returns a request URI.
Types ¶
type OpenWeatherCurrent ¶
type OpenWeatherCurrent struct { Coord `json:"coord"` Weather []Weather `json:"weather"` Base string `json:"base"` Main `json:"main"` Visibility int `json:"visibility"` Wind `json:"wind"` Clouds `json:"clouds"` DT int32 `json:"dt"` Sys `json:"sys"` Timezone int `json:"timezone"` ID int32 `json:"id"` Name string `json:"name"` Cod int `json:"cod"` }
func (*OpenWeatherCurrent) PrettyPrint ¶
func (w *OpenWeatherCurrent) PrettyPrint() string
PrettyPrint uses a template to print nicely formatted weather output.
Click to show internal directories.
Click to hide internal directories.