31 lines
641 B
Go
31 lines
641 B
Go
|
|
package constants
|
||
|
|
|
||
|
|
import "time"
|
||
|
|
|
||
|
|
const (
|
||
|
|
// ObservationWindow defines how far back observations are queried.
|
||
|
|
ObservationWindow = 30 * time.Minute
|
||
|
|
|
||
|
|
// ForecastQueryLimit defines the max forecast periods returned.
|
||
|
|
ForecastQueryLimit = 5
|
||
|
|
|
||
|
|
// DefaultOutputUnitSystem is the API's default output unit system.
|
||
|
|
DefaultOutputUnitSystem = "us"
|
||
|
|
|
||
|
|
// DefaultHTTPAddr is the default listen address for the HTTP server.
|
||
|
|
DefaultHTTPAddr = ":8080"
|
||
|
|
)
|
||
|
|
|
||
|
|
var SupportedTimestampLayouts = []string{
|
||
|
|
time.RFC3339Nano,
|
||
|
|
time.RFC3339,
|
||
|
|
}
|
||
|
|
|
||
|
|
const (
|
||
|
|
TempFahrenheitPrecision = 1
|
||
|
|
WindMphPrecision = 1
|
||
|
|
|
||
|
|
KmhPerMph = 1.609344
|
||
|
|
MphPerKmh = 1 / KmhPerMph
|
||
|
|
)
|