Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ValidateStationID ¶
func ValidateStationName ¶
func ValidateStationName(sn StationName) bool
Types ¶
type Data ¶
type Data struct { RawTimestamp RawEntryTime `json:"raw_time_data"` Timestamp time.Time `json:"timestamp"` // Solar Radiation SolarZenithAngle float64 `json:"solar_zenith_angle,omitempty"` DownwellingSolar float64 `json:"downwelling_solar,omitempty"` UpwellingSolar float64 `json:"upwelling_solar,omitempty"` DirectNormalSolar float64 `json:"direct_normal_solar,omitempty"` DownwellingDiffuseSolar float64 `json:"downwelling_diffuse_solar,omitempty"` DownwellingIR float64 `json:"downwelling_ir,omitempty"` DownwellingIRCaseTemp float64 `json:"downwelling_ir_case_temp,omitempty"` DownwellingIRDomeTemp float64 `json:"downwelling_ir_dome_temp,omitempty"` UpwellingIR float64 `json:"upwelling_ir,omitempty"` UpwellingIRCaseTemp float64 `json:"upwelling_ir_case_temp,omitempty"` UpwellingIRDomeTemp float64 `json:"upwelling_ir_dome_temp,omitempty"` GlobalUVB float64 `json:"global_uvb,omitempty"` PhotosyntheticallyActiveRadiation float64 `json:"photosynthetically_active_radiation,omitempty"` NetSolar float64 `json:"net_solar,omitempty"` NetIR float64 `json:"net_ir,omitempty"` TotalNetRadiation float64 `json:"total_net,omitempty"` TemperatureC float64 `json:"temperature,omitempty"` // celcius RelativeHumidity float64 `json:"relative_humidity,omitempty"` WindSpeedMetersPerSecond float64 `json:"wind_speed,omitempty"` // m/s WindDirectionDegrees float64 `json:"wind_direction,omitempty"` // degrees, clockwise from north BarometricPressure float64 `json:"barometric_pressure,omitempty"` // mb }
func (*Data) OmitInvalidOrMissing ¶
func (d *Data) OmitInvalidOrMissing()
func (*Data) ParseTimestamp ¶
type RawEntryTime ¶
type Station ¶
type Station struct { StationName StationName `json:"station_name"` LocatedAt Location `json:"located_at"` Version int `json:"version"` Entries []Data `json:"entries"` }
type StationID ¶
type StationID [3]rune
var ( StationIDBondville StationID = [3]rune{'b', 'o', 'n'} StationIDFortPeck StationID = [3]rune{'f', 'p', 'k'} StationIDGoodwinCreek StationID = [3]rune{'g', 'w', 'n'} StationIDTableMountain StationID = [3]rune{'t', 'b', 'l'} StationIDDesertRock StationID = [3]rune{'d', 'r', 'a'} StationIDPennState StationID = [3]rune{'p', 's', 'u'} StationIDSiouxFalls StationID = [3]rune{'s', 'x', 'f'} StationIDToName = map[StationID]StationName{ StationIDBondville: StationBondville, StationIDFortPeck: StationFortPeck, StationIDGoodwinCreek: StationGoodwinCreek, StationIDTableMountain: StationTableMountain, StationIDDesertRock: StationDesertRock, StationIDPennState: StationPennState, StationIDSiouxFalls: StationSiouxFalls, } NameToStationID = map[StationName]StationID{ StationBondville: StationIDBondville, StationFortPeck: StationIDFortPeck, StationGoodwinCreek: StationIDGoodwinCreek, StationTableMountain: StationIDTableMountain, StationDesertRock: StationIDDesertRock, StationPennState: StationIDPennState, StationSiouxFalls: StationIDSiouxFalls, } )
func GetStationID ¶
func GetStationID(sn StationName) (StationID, bool)
type StationName ¶
type StationName string
const ( StationBondville StationName = "Bondville" StationFortPeck StationName = "Fort Peck" StationGoodwinCreek StationName = "Goodwin Creek" StationTableMountain StationName = "Table Mountain" StationDesertRock StationName = "Desert Rock" StationPennState StationName = "Penn State" StationSiouxFalls StationName = "Sioux Falls" )
func GetStationName ¶
func GetStationName(sid StationID) (StationName, bool)
func (StationName) String ¶
func (sn StationName) String() string
func (StationName) Valid ¶
func (sn StationName) Valid() bool
Click to show internal directories.
Click to hide internal directories.