trafikinfo

package module
v0.4.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 10, 2022 License: MIT Imports: 4 Imported by: 0

README ¶

🚦 Trafikinfo 🦺

A Go library for the Trafikinfo API from Trafikverket

Build Status Release Coverage Status Go report card GoDoc

This library provides the necessary primitives to interact with the Trafikinfo API. It contains a query builder that can be used to build up a Request object. You can then xml.Marshal it and pass it on to your favourite HTTP client to retrieve it.

The data returned by the Trafikinfo API is licensed under Creative Commons CC0.

The API endpoint is available through the Endpoint constant. The only supported endpoint is v2, v1.x is being deprecated by Trafikverket.

The provided structs in the library have a somewhat odd design in that all fields are pointers. This happens because the structs are largely autogenerated from the JSON schema which defines all attributes as optional. This is a consequence of the Include and Exclude primitives which can result in only specific fields being present in the response, or specific fields be excluded.

Usage

req, err := trafikinfo.NewRequest().
	APIKey("YOUR_API_KEY").
	Query(
		trafikinfo.NewQuery(
			trafikinfo.WeatherStation,
			1.0,
		).Filter(
			trafikinfo.Equal("Id", "YOUR_STATION_ID"),
		),
	).Build()

if err != nil {
	panic(err)
}

// Rest of the code here to do the request, handle non-200 error
// responses etc.

type respMsg struct {
	Resonpse struct {
		Result []struct {
			WeatherStation []trafikinfo.WeatherStation1Dot0 `json:"WeatherStation"`
			Info           trafikinfo.Info                  `json:"INFO"`
		}
	} `json:"RESPONSE"`
}

var c respMsg
d := json.NewDecoder(resp.Body)
err = d.Decode(&c)

if err != nil {
	panic(err)
}

// Enjoy your struct!

More complete code can be found in the examples/ directory.

Multiple queries can be passed by either passing multiple NewQuery() into a single Query() call, or chaining .Query() multiple times on the result of NewRequest().

Calling .Filter() multiple times on a Query will replace the whole filter, as a query can only have one filter block.

Supported object types

This library provides structs for response decoding for the following object types and versions.

Object Versions
Camera 1.0: âś…
FerryAnnouncement 1.2: âś…
FerryRoute 1.2: âś…
Icon 1.0: âś…
MeasurementData100 1.0: âś…
MeasurementData20 1.0: âś…
Parking 1.0: âś… 1.4: âś…
PavementData 1.0: âś…
RailCrossing 1.4: âś… 1.5: âś…
ReasonCode 1.0: âś…
RoadCondition 1.0: âś… 1.1: âś… 1.2: âś…
RoadConditionOverview 1.0: âś…
RoadData 1.0: âś…
RoadGeometry 1.0: âś…
Situation 1.0: âś… 1.1: âś… 1.2: âś… 1.4: âś… 1.5: âś…
TrafficFlow 1.0: âś… 1.4: âś…
TrafficSafetyCamera 1.0: âś…
TrainAnnouncement 1.0: âś… 1.3: âś… 1.4: âś… 1.5: âś… 1.6: âś…
TrainMessage 1.0: âś… 1.3: âś… 1.4: âś… 1.5: âś… 1.6: âś… 1.7: âś…
TrainStation 1.0: âś… 1.4: âś…
TrainStationMessage 1.0: âś…
TravelTimeRoute 1.0: âś… 1.3: âś… 1.4: âś… 1.5 âś…
WeatherMeasurepoint 1.0: âś… 2.0: âś…
WeatherObservation 1.0: âś… 2.0: âś…
WeatherStation 1.0: âś…

Documentation ¶

Overview ¶

Package trafikinfo provides the necessary primitives to interact with the Trafikinfo API. It contains a query builder that can be used to build up a Request object. You can then xml.Marshal it and pass it on to your favourite HTTP client to retrieve it through a bytes.Buffer.

The data returned by the Trafikinfo API is licensed under Creative Commons CC0: * https://api.trafikinfo.trafikverket.se/DynamicContent/ContentDetails/58e384810bb22118e8041667 * https://creativecommons.org/publicdomain/zero/1.0/.

The API endpoint is available through the Endpoint constant. The only supported endpoint is v2, v1.x is being deprecated by Trafikverket.

The provided structs in the library have a somewhat odd design in that all fields are pointers. This happens because the structs are largely autogenerated from the JSON schema which defines all attributes as optional. This is a consequence of the Include and Exclude primitives which can result in only specific fields being present in the response, or specific fields be excluded.

A number of endpoints return IconID resources, either at the root of the object, or in one of its embedded objects, like TemperatureIconID. Each of these IconID strings can be plugged into a query for the Icon resource. It in turn will give you access to a base64 encoded PNG in the response, as well as a URL at which the icon can be retrieved.

Index ¶

Constants ¶

View Source
const Endpoint = "https://api.trafikinfo.trafikverket.se/v2/data.json"

Endpoint is the current recommended endpoint for the Trafikinfo API

Variables ¶

This section is empty.

Functions ¶

This section is empty.

Types ¶

type APIError ¶ added in v0.3.1

type APIError struct {
	Response struct {
		Result []struct {
			Error struct {
				Message string `json:"MESSAGE"`
				Source  string `json:"SOURCE"`
			} `json:"ERROR"`
		} `json:"RESULT"`
	} `json:"RESPONSE"`
}

APIError represents an error response from the API

type Accessibility ¶ added in v0.3.0

type Accessibility string
const (
	AccessibilityBarrierFreeAccessible           Accessibility = "barrierFreeAccessible"
	AccessibilityHandicappedAccessible           Accessibility = "handicappedAccessible"
	AccessibilityHandicappedEasements            Accessibility = "handicappedEasements"
	AccessibilityHandicappedMarked               Accessibility = "handicappedMarked"
	AccessibilityOrientationSystemForBlindPeople Accessibility = "orientationSystemForBlindPeople"
	AccessibilityWheelChairAccessible            Accessibility = "wheelChairAccessible"

	AccessibilityNone    Accessibility = "none"
	AccessibilityUnknown Accessibility = "unknown"
	AccessibilityOther   Accessibility = "other"
)

type ActivityType ¶ added in v0.2.0

type ActivityType string
const (
	ActivityTypeArrival   ActivityType = "Ankomst"
	ActivityTypeDeparture ActivityType = "Avgang"
)

type AffectedDirection ¶ added in v0.4.2

type AffectedDirection string
const (
	AffectedDirectionBoth AffectedDirection = "BothDirections"
	AffectedDirectionOne  AffectedDirection = "OneDirection"
)

type Camera1Dot0 ¶ added in v0.3.0

type Camera1Dot0 struct {
	Active           *bool       `json:"Active,omitempty"`
	CameraGroup      *string     `json:"CameraGroup,omitempty"`
	ContentType      *string     `json:"ContentType,omitempty"`
	County           []County    `json:"CountyNo,omitempty"`
	Deleted          *bool       `json:"Deleted,omitempty"`
	Description      *string     `json:"Description,omitempty"`
	Direction        *int        `json:"Direction,omitempty"`
	Geometry         *Geometry   `json:"Geometry,omitempty"`
	HasFullSizePhoto *bool       `json:"HasFullSizePhoto,omitempty"`
	HasSketchImage   *bool       `json:"HasSketchImage,omitempty"`
	IconID           *string     `json:"IconId,omitempty"`
	ID               *string     `json:"Id,omitempty"`
	Location         *string     `json:"Location,omitempty"`
	ModifiedTime     *time.Time  `json:"ModifiedTime,omitempty"`
	Name             *string     `json:"Name,omitempty"`
	PhotoTime        *time.Time  `json:"PhotoTime,omitempty"`
	PhotoURL         *string     `json:"PhotoUrl,omitempty"`
	Status           *string     `json:"Status,omitempty"`
	Type             *CameraType `json:"Type,omitempty"`
}

type CameraType ¶ added in v0.3.0

type CameraType string
const (
	CameraTypeSpeed CameraType = "Väglagskamera"
	CameraTypeFlow  CameraType = "Trafikflödeskamera"
)

type Cause ¶ added in v0.3.0

type Cause string
const (
	CauseFog                 Cause = "Dimma"
	CauseFallingTemperatures Cause = "Fallande temperatur"
	CauseFrost               Cause = "Frost"
	CauseRain                Cause = "Regn"
	CauseMeltedWater         Cause = "Smältvatten"
	CauseSnowdrift           Cause = "Snödrev"
	CauseSnow                Cause = "Snöfall"
	CauseFreezingRain        Cause = "Underkylt regn"
)

type Condition ¶ added in v0.3.0

type Condition uint
const (
	ConditionNormal Condition = iota + 1
	ConditionDifficult
	ConditionVeryDifficult
	ConditionIceAndSnow
)

func (Condition) String ¶ added in v0.3.0

func (c Condition) String() string

type Country ¶ added in v0.3.0

type Country string

Country represents a country through its country code

const (
	CountryGermany Country = "DE"
	CountryDenmark Country = "DK"
	CountryNorway  Country = "NO"
	CountrySweden  Country = "SE"
)

type County ¶ added in v0.3.0

type County uint

County is a numerical ID assigned to a county in Sweden

const (
	CountyStockholm County = iota + 1
	CountyStockholmDeprecated
	CountyUppsala
	CountySodermanland
	CountyOstergotland
	CountyJonkoping
	CountyKronobergs
	CountyKalmar
	CountyGotland
	CountyBlekinge

	CountySkane
	CountyHallands
	CountyVastraGotaland

	CountyVarmland
	CountyOrebro
	CountyVastmanland
	CountyDalarna
	CountyGavleborg
	CountyVasternorrland
	CountyJamtland
	CountyVasterbotten
	CountyNorrbotten
)

func (County) String ¶ added in v0.3.0

func (c County) String() string

type DeviationType ¶ added in v0.3.0

type DeviationType string
const (
	DeviationTypeMessage   DeviationType = "Meddelande"
	DeviationTypeSummon    DeviationType = "Kallelse"
	DeviationTypeGoing     DeviationType = "GĂĄr"
	DeviationTypeCancelled DeviationType = "GĂĄr ej"
)

type Equipment ¶ added in v0.3.0

type Equipment string
const (
	EquipmentBikeParking             Equipment = "bikeParking"
	EquipmentCashMachine             Equipment = "cashMachine"
	EquipmentCopyMachineOrService    Equipment = "copyMachineOrService"
	EquipmentDefibrillator           Equipment = "defibrillator"
	EquipmentDumpingStation          Equipment = "dumpingStation"
	EquipmentElectricChargingStation Equipment = "electricChargingStation"
	EquipmentElevator                Equipment = "elevator"
	EquipmentFaxMachineOrService     Equipment = "faxMachineOrService"
	EquipmentFireExtingiusher        Equipment = "fireExtingiusher"
	EquipmentFireHose                Equipment = "fireHose"
	EquipmentFireHydrant             Equipment = "fireHydrant"
	EquipmentFirstAidEquipment       Equipment = "firstAidEquipment"
	EquipmentFreshWater              Equipment = "freshWater"
	EquipmentIceFreeScaffold         Equipment = "iceFreeScaffold"
	EquipmentInformationPoint        Equipment = "informationPoint"
	EquipmentInformatonStele         Equipment = "informatonStele"
	EquipmentInternetTerminal        Equipment = "internetTerminal"
	EquipmentInternetWireless        Equipment = "internetWireless"
	EquipmentLuggageLocker           Equipment = "luggageLocker"
	EquipmentPayDesk                 Equipment = "payDesk"
	EquipmentPaymentMachine          Equipment = "paymentMachine"
	EquipmentPicnicFacilities        Equipment = "picnicFacilities"
	EquipmentPlayground              Equipment = "playground"
	EquipmentPublicCardPhone         Equipment = "publicCardPhone"
	EquipmentPublicCoinPhone         Equipment = "publicCoinPhone"
	EquipmentPublicPhone             Equipment = "publicPhone"
	EquipmentRefuseBin               Equipment = "refuseBin"
	EquipmentSafeDeposit             Equipment = "safeDeposit"
	EquipmentShower                  Equipment = "shower"
	EquipmentToilet                  Equipment = "toilet"
	EquipmentTollTerminal            Equipment = "tollTerminal"
	EquipmentVendingMachine          Equipment = "vendingMachine"
	EquipmentWasteDisposal           Equipment = "wasteDisposal"

	EquipmentNone    Equipment = "none"
	EquipmentOther   Equipment = "other"
	EquipmentUnknown Equipment = "unknown"
)

type Evaluation ¶ added in v0.3.0

type Evaluation struct {
	// contains filtered or unexported fields
}

func Eval ¶ added in v0.3.0

func Eval(alias, function string) Evaluation

func (*Evaluation) MarshalXML ¶ added in v0.3.0

func (v *Evaluation) MarshalXML(e *xml.Encoder, start xml.StartElement) error

type Facility ¶ added in v0.3.0

type Facility string
const (
	FacilityHotel                   Facility = "hotel"
	FacilityMotel                   Facility = "motel"
	FacilityOvernightAccommodation  Facility = "overnightAccommodation"
	FacilityShop                    Facility = "shop"
	FacilityKiosk                   Facility = "kiosk"
	FacilityFoodShopping            Facility = "foodShopping"
	FacilityCafe                    Facility = "cafe"
	FacilityRestaurant              Facility = "restaurant"
	FacilityRestaurantSelfService   Facility = "restaurantSelfService"
	FacilityMotorwayRestaurant      Facility = "motorwayRestaurant"
	FacilityMotorwayRestaurantSmall Facility = "motorwayRestaurantSmall"
	FacilitySparePartsShopping      Facility = "sparePartsShopping"
	FacilityPetrolStation           Facility = "petrolStation"
	FacilityVehicleMaintenance      Facility = "vehicleMaintenance"
	FacilityTyreRepair              Facility = "tyreRepair"
	FacilityTruckRepair             Facility = "truckRepair"
	FacilityTruckWash               Facility = "truckWash"
	FacilityCarWash                 Facility = "carWash"
	FacilityPharmacy                Facility = "pharmacy"
	FacilityMedicalFacility         Facility = "medicalFacility"
	FacilityPolice                  Facility = "police"
	FacilityTouristInformation      Facility = "touristInformation"
	FacilityBikeSharing             Facility = "bikeSharing"
	FacilityDocstop                 Facility = "docstop"
	FacilityLaundry                 Facility = "laundry"
	FacilityLeisureActivities       Facility = "leisureActivities"

	FacilityUnknown Facility = "unknown"
	FacilityOther   Facility = "other"
)

type FerryAnnouncement1Dot2 ¶ added in v0.3.0

type FerryAnnouncement1Dot2 struct {
	Deleted       *bool      `json:"Deleted,omitempty"`
	DepartureTime *time.Time `json:"DepartureTime,omitempty"`
	DeviationID   *string    `json:"DeviationId,omitempty"`
	FromHarbor    *struct {
		ID   *int    `json:"Id,omitempty"`
		Name *string `json:"Name,omitempty"`
	} `json:"FromHarbor,omitempty"`
	ID           *int       `json:"Id,omitempty"`
	Info         []string   `json:"Info,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	Route        *struct {
		ID        *int    `json:"Id,omitempty"`
		Name      *string `json:"Name,omitempty"`
		Shortname *string `json:"Shortname,omitempty"`
		Type      *struct {
			ID   *int    `json:"Id,omitempty"`
			Name *string `json:"Name,omitempty"`
		} `json:"Type,omitempty"`
	} `json:"Route,omitempty"`
	ToHarbor *struct {
		ID   *int    `json:"Id,omitempty"`
		Name *string `json:"Name,omitempty"`
	} `json:"ToHarbor,omitempty"`
}

type FerryRoute1Dot2 ¶ added in v0.3.0

type FerryRoute1Dot2 struct {
	Deleted     *bool     `json:"Deleted,omitempty"`
	DeviationID *string   `json:"DeviationId,omitempty"`
	Geometry    *Geometry `json:"Geometry,omitempty"`
	Harbor      []struct {
		ID        *int    `json:"Id,omitempty"`
		Name      *string `json:"Name,omitempty"`
		SortOrder *int    `json:"SortOrder,omitempty"`
		StopType  *struct {
			ID      *int      `json:"Id,omitempty"`
			Name    *StopType `json:"Name,omitempty"`
			Visible *bool     `json:"Visible,omitempty"`
		} `json:"StopType,omitempty"`
	} `json:"Harbor,omitempty"`
	ID           *int       `json:"Id,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	Name         *string    `json:"Name,omitempty"`
	Shortname    *string    `json:"Shortname,omitempty"`
	Timetable    []struct {
		Description *string `json:"Description,omitempty"`
		Period      []struct {
			Name     *string `json:"Name,omitempty"`
			Schedule []struct {
				Deviation []struct {
					Description *string `json:"Description,omitempty"`
					FromDate    *string `json:"FromDate,omitempty"`
					ID          *string `json:"Id,omitempty"`
					SpecDate    *string `json:"SpecDate,omitempty"`
					ToDate      *string `json:"ToDate,omitempty"`
					Type        *struct {
						ID   *string        `json:"Id,omitempty"`
						Name *DeviationType `json:"Name,omitempty"`
					} `json:"Type,omitempty"`
				} `json:"Deviation,omitempty"`
				Harbor *struct {
					ID        *int    `json:"Id,omitempty"`
					Name      *string `json:"Name,omitempty"`
					SortOrder *int    `json:"SortOrder,omitempty"`
					StopType  *struct {
						ID      *int      `json:"Id,omitempty"`
						Name    *StopType `json:"Name,omitempty"`
						Visible *bool     `json:"Visible,omitempty"`
					} `json:"StopType,omitempty"`
				} `json:"Harbor,omitempty"`
				SortOrder *int `json:"SortOrder,omitempty"`
				StopType  *struct {
					ID      *int      `json:"Id,omitempty"`
					Name    *StopType `json:"Name,omitempty"`
					Visible *bool     `json:"Visible,omitempty"`
				} `json:"StopType,omitempty"`
				Time *string `json:"Time,omitempty"`
			} `json:"Schedule,omitempty"`
			SortOrder *int `json:"SortOrder,omitempty"`
			Weekday   []struct {
				ID  *int    `json:"Id,omitempty"`
				Day *string `json:"Day,omitempty"`
			} `json:"Weekday,omitempty"`
		} `json:"Period,omitempty"`
		Priority *int `json:"Priority,omitempty"`
		Valid    []struct {
			From *time.Time `json:"From,omitempty"`
			To   *time.Time `json:"To,omitempty"`
		} `json:"Valid,omitempty"`
	} `json:"Timetable,omitempty"`
	Type *struct {
		ID   *int    `json:"Id,omitempty"`
		Name *string `json:"Name,omitempty"`
	} `json:"Type,omitempty"`
}

type Filter ¶

type Filter struct {
	// contains filtered or unexported fields
}

Filter represents a filter element in the query.

func And ¶

func And(f1, f2 Filter, rest ...Filter) Filter

And builds an AND filter

func ElementMatch ¶

func ElementMatch(f1, f2 Filter, rest ...Filter) Filter

ElementMatch builds an ELEMENTMATCH filter

func Equal ¶

func Equal(name, value string) Filter

Equal filters by if the field provided by name matches the specified value

func Exists ¶

func Exists(name string, exists bool) Filter

Exists filters by whether the field provided by name exists or not

func GreaterThan ¶

func GreaterThan(name, value string) Filter

GreaterThan filters by whether the field specified by name is greater than the specified value

func GreaterThanOrEqual ¶

func GreaterThanOrEqual(name, value string) Filter

GreaterThanOrEqual filters by whether the field specified by name is greater than or equal to the specified value

func In ¶

func In(name, value string) Filter

In filters by if the field specified by name matches any of the provided values

func Intersects ¶

func Intersects(name, value string) Filter

Intersects filters by if te field specified in name intersects with the coordinates provided in value

func LessThan ¶

func LessThan(name, value string) Filter

LessThan filters by whether the field specified by name is less than the specified value

func LessThanOrEqual ¶

func LessThanOrEqual(name, value string) Filter

LessThanOrEqual filters by whether the field specified by name is less than or equal to the specified value

func Like ¶

func Like(name, value string) Filter

Like filters by if the field provided by name matches the regex provided by value

func Near ¶

func Near(name, value string, minDistance, maxDistance int) Filter

Near filters by if the field specified in name is within the specified min/max dinstance from the point coordinates sepcified in value

func Not ¶

func Not(f1, f2 Filter, rest ...Filter) Filter

Not builds an NOT filter

func NotEqual ¶

func NotEqual(name, value string) Filter

NotEqual is the inverse of Equal

func NotIn ¶

func NotIn(name, value string) Filter

NotIn is the inverse of In

func NotLike ¶

func NotLike(name, value string) Filter

NotLIke is the inverse of Like

func Or ¶

func Or(f1, f2 Filter, rest ...Filter) Filter

Or builds an OR filter

func Within ¶

func Within(name, value, shape string, radius float64) Filter

Within filters by if the field specified in name falls within the specified shape, radius and the coordinates in value

func (*Filter) MarshalXML ¶

func (f *Filter) MarshalXML(e *xml.Encoder, start xml.StartElement) error

type Geometry ¶ added in v0.2.0

type Geometry struct {
	// SWEREF99TM, SWEdish REference Frame 1999, Transverse Mercator,
	// is a projected coordinate system to identify geographical
	// locations in Sweden
	SWEREF99TM *string `json:"SWEREF99TM,omitempty"`
	// WGS84 represents coordinates in the World Geodetic System
	// 1984 revision.
	WGS84 *string `json:"WGS84,omitempty"`
}

Geometry represents a set of coordinates that result denote a location

type GeometryWithMod ¶ added in v0.3.0

type GeometryWithMod struct {
	Geometry
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
}

type Icon1Dot0 ¶ added in v0.3.0

type Icon1Dot0 struct {
	Base64       *string    `json:"Base64,omitempty"`
	Deleted      *bool      `json:"Deleted,omitempty"`
	Description  *string    `json:"Description,omitempty"`
	ID           *string    `json:"Id,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	URL          *string    `json:"Url,omitempty"`
}

type Info ¶ added in v0.2.0

type Info struct {
	LastModified *struct {
		DateTime *time.Time `json:"_attr_datetime,omitempty"`
	} `json:"LASTMODIFIED,omitempty"`
	LastChangeID *string `json:"LASTCHANGEID,omitempty"`
	EvalResult   []any   `json:"EVALRESULT,omitempty"`
	SSEURL       *string `json:"SSEURL,omitempty"`
}

Info is part of the response API when a query is created with either an EVAL or the use of a Change ID

type Measurement ¶ added in v0.3.0

type Measurement string
const (
	MeasurementPreventiveAntiSlip Measurement = "Förebyggande halkbekämpning"
	MeasurementAntiSlip           Measurement = "Halkbekämpning"
	MeasurementIcePlowing         Measurement = "Ishyvling"
	MeasurementSnowPlowing        Measurement = "Plogning"
	MeasurementSanding            Measurement = "Sandning"
	MeasurementOther              Measurement = "Annat"
)

type MeasurementData1001Dot0 ¶ added in v0.3.0

type MeasurementData1001Dot0 struct {
	County    *County `json:"County,omitempty"`
	Deleted   *bool   `json:"Deleted,omitempty"`
	Direction *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"Direction,omitempty"`
	EdgeDepthAverageValue       *float64 `json:"EdgeDepthAverageValue,omitempty"`
	EndContinuousLength         *int     `json:"EndContinuousLength,omitempty"`
	IRIRightAverageValue        *float64 `json:"IRIRightAverageValue,omitempty"`
	Lane                        *int     `json:"Lane,omitempty"`
	Length                      *int     `json:"Length,omitempty"`
	MPDMacrotextureAverageValue *float64 `json:"MPDMacrotextureAverageValue,omitempty"`
	MeasurementDataType         *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"MeasurementDataType,omitempty"`
	MeasurementDate           *string    `json:"MeasurementDate,omitempty"`
	MeasurementDateSpecific   *string    `json:"MeasurementDateSpecific,omitempty"`
	ModifiedTime              *time.Time `json:"ModifiedTime,omitempty"`
	RoadMainNumber            *int       `json:"RoadMainNumber,omitempty"`
	RoadSubNumber             *int       `json:"RoadSubNumber,omitempty"`
	RutDepthMax15AverageValue *float64   `json:"RutDepthMax15AverageValue,omitempty"`
	RutDepthMax17AverageValue *float64   `json:"RutDepthMax17AverageValue,omitempty"`
	StartContinuousLength     *int       `json:"StartContinuousLength,omitempty"`
	Timestamp                 *time.Time `json:"TimeStamp,omitempty"`
}

type MeasurementData201Dot0 ¶ added in v0.3.0

type MeasurementData201Dot0 struct {
	County             *County  `json:"County,omitempty"`
	CrossfallRutBottom *float64 `json:"CrossfallRutBottom,omitempty"`
	Curvature          *float64 `json:"Curvature,omitempty"`
	Deleted            *bool    `json:"Deleted,omitempty"`
	Direction          *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"Direction,omitempty"`
	EdgeDepth             *float64 `json:"EdgeDepth,omitempty"`
	EndContinuousLength   *int     `json:"EndContinuousLength,omitempty"`
	Hilliness             *float64 `json:"Hilliness,omitempty"`
	IRILeft               *float64 `json:"IRILeft,omitempty"`
	IRIRight              *float64 `json:"IRIRight,omitempty"`
	Lane                  *int     `json:"Lane,omitempty"`
	Length                *int     `json:"Length,omitempty"`
	MPDMacrotextureLeft   *float64 `json:"MPDMacrotextureLeft,omitempty"`
	MPDMacrotextureMiddle *float64 `json:"MPDMacrotextureMiddle,omitempty"`
	MPDMacrotextureRight  *float64 `json:"MPDMacrotextureRight,omitempty"`
	MeasurementDataType   *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"MeasurementDataType,omitempty"`
	MeasurementDate         *string    `json:"MeasurementDate,omitempty"`
	MeasurementDateSpecific *string    `json:"MeasurementDateSpecific,omitempty"`
	MeasurementVehicleSpeed *float64   `json:"MeasurementVehicleSpeed,omitempty"`
	MegatextureLeft         *float64   `json:"MegatextureLeft,omitempty"`
	MegatextureRight        *float64   `json:"MegatextureRight,omitempty"`
	ModifiedTime            *time.Time `json:"ModifiedTime,omitempty"`
	RoadMainNumber          *int       `json:"RoadMainNumber,omitempty"`
	RoadSubNumber           *int       `json:"RoadSubNumber,omitempty"`
	RutArea                 *float64   `json:"RutArea,omitempty"`
	RutBottomDistance       *float64   `json:"RutBottomDistance,omitempty"`
	RutDepthLeft17          *float64   `json:"RutDepthLeft17,omitempty"`
	RutDepthMax15           *float64   `json:"RutDepthMax15,omitempty"`
	RutDepthMax17           *float64   `json:"RutDepthMax17,omitempty"`
	RutDepthRight15         *float64   `json:"RutDepthRight15,omitempty"`
	RutDepthRight17         *float64   `json:"RutDepthRight17,omitempty"`
	RutWidthLeft            *float64   `json:"RutWidthLeft,omitempty"`
	RutWidthRight           *float64   `json:"RutWidthRight,omitempty"`
	StartContinuousLength   *int       `json:"StartContinuousLength,omitempty"`
	Timestamp               *time.Time `json:"TimeStamp,omitempty"`
	WaterArea               *float64   `json:"WaterArea,omitempty"`
}

type MediaType ¶ added in v0.2.0

type MediaType string
const (
	MediaTypeMonitor      MediaType = "Monitor"
	MediaTypePlatformSign MediaType = "Plattformsskylt"
	MediaTypeAnnouncement MediaType = "Utrop"
)

type MessageStatus ¶ added in v0.2.0

type MessageStatus string
const (
	MessageStatusLow        MessageStatus = "Lag"
	MessageStatusNormal     MessageStatus = "Normal"
	MessageStatusHigh       MessageStatus = "Hog"
	MessageStatusDisruption MessageStatus = "StortLage"
)

type MessageType ¶ added in v0.4.2

type MessageType string
const (
	MessageTypeImportant    MessageType = "Viktig trafikinformation"
	MessageTypeFerries      MessageType = "Färjor"
	MessageTypeHinder       MessageType = "Hinder"
	MessageTypeAccident     MessageType = "Olycka"
	MessageTypeRestriction  MessageType = "Restriktion"
	MessageTypeAnnouncement MessageType = "Trafikmeddelande"
	MessageTypeRoadWork     MessageType = "Vägarbete"
)

type ObjectType ¶

type ObjectType string

ObjectType is a type of object you can retrieve from the API

const (
	RailCrossing        ObjectType = "RailCrossing"
	ReasonCode          ObjectType = "ReasonCode"
	TrainAnnouncement   ObjectType = "TrainAnnouncement"
	TrainMessage        ObjectType = "TrainMessage"
	TrainStation        ObjectType = "TrainStation"
	TrainStationMessage ObjectType = "TrainStationMessage"
	TrainPosition       ObjectType = "TrainPosition"

	Camera                ObjectType = "Camera"
	FerryAnnouncement     ObjectType = "FerryAnnouncement"
	FerryRoute            ObjectType = "FerryRoute"
	Icon                  ObjectType = "Icon"
	Parking               ObjectType = "Parking"
	RoadCondition         ObjectType = "RoadCondition"
	RoadConditionOverview ObjectType = "RoadConditionOverview"
	Situation             ObjectType = "Situation"
	TrafficFlow           ObjectType = "TrafficFlow"
	TrafficSafetyCamera   ObjectType = "TrafficSafetyCamera"
	TravelTimeRoute       ObjectType = "TravelTimeRoute"
	WeatherMeasurePoint   ObjectType = "WeatherMeasurePoint"
	WeatherObservation    ObjectType = "WeatherObservation"
	WeatherStation        ObjectType = "WeatherStation"

	MeasurementData100 ObjectType = "MeasurementData100"
	MeasurementData20  ObjectType = "MeasurementData20"
	PavementData       ObjectType = "PavementData"
	RoadData           ObjectType = "RoadData"
	RoadGeometry       ObjectType = "RoadGeometry"
)

type Origin ¶ added in v0.4.0

type Origin string
const (
	OriginCalculated Origin = "calculated"
	OriginEstimated  Origin = "estimated"
	OriginMeasured   Origin = "measured"
)

type Parking1Dot0 ¶ added in v0.3.0

type Parking1Dot0 struct {
	County                []County `json:"CountyNo,omitempty"`
	Deleted               *bool    `json:"Deleted,omitempty"`
	Description           *string  `json:"Description,omitempty"`
	DistanceToNearestCity *string  `json:"DistanceToNearestCity,omitempty"`
	Equipment             []struct {
		Accessibility *Accessibility `json:"Accessibility,omitempty"`
		Type          *Equipment     `json:"Type,omitempty"`
	} `json:"Equipment,omitempty"`
	Facility []struct {
		Accessibility *Accessibility `json:"Accessibility,omitempty"`
		Type          *Facility      `json:"Type,omitempty"`
	} `json:"Facility,omitempty"`
	Geometry            *Geometry  `json:"Geometry,omitempty"`
	IconID              *string    `json:"IconId,omitempty"`
	ID                  *string    `json:"Id,omitempty"`
	LocationDescription *string    `json:"LocationDescription,omitempty"`
	ModifiedTime        *time.Time `json:"ModifiedTime,omitempty"`
	Name                *string    `json:"Name,omitempty"`
	OpenStatus          *string    `json:"OpenStatus,omitempty"`
	OperationStatus     *string    `json:"OperationStatus,omitempty"`
	Operator            *struct {
		Contact                *string `json:"Contact,omitempty"`
		ContactEmail           *string `json:"ContactEmail,omitempty"`
		ContactTelephoneNumber *string `json:"ContactTelephoneNumber,omitempty"`
		Name                   *string `json:"Name,omitempty"`
	} `json:"Operator,omitempty"`
	ParkingAccess []Geometry `json:"ParkingAccess,omitempty"`
	Photo         []struct {
		Title *string `json:"Title,omitempty"`
		URL   *string `json:"Url,omitempty"`
	} `json:"Photo,omitempty"`
	TariffsAndPayment *struct {
		FreeOfCharge *bool   `json:"FreeOfCharge,omitempty"`
		Tariff       *string `json:"Tariff,omitempty"`
	} `json:"TariffsAndPayment,omitempty"`
	UsageSenario           []string `json:"UsageSenario,omitempty"`
	VehicleCharacteristics []struct {
		LoadType       *string  `json:"LoadType,omitempty"`
		NumberOfSpaces *int     `json:"NumberOfSpaces,omitempty"`
		VehicleType    *Vehicle `json:"VeichleType,omitempty"`
	} `json:"VehicleCharacteristics,omitempty"`
}

type Parking1Dot4 ¶ added in v0.3.0

type Parking1Dot4 struct {
	County                []County `json:"CountyNo,omitempty"`
	Deleted               *bool    `json:"Deleted,omitempty"`
	Description           *string  `json:"Description,omitempty"`
	DistanceToNearestCity *string  `json:"DistanceToNearestCity,omitempty"`
	Equipment             []struct {
		Accessibility *Accessibility `json:"Accessibility,omitempty"`
		Type          *Equipment     `json:"Type,omitempty"`
	} `json:"Equipment,omitempty"`
	Facility []struct {
		Accessibility *Accessibility `json:"Accessibility,omitempty"`
		Type          *Facility      `json:"Type,omitempty"`
	} `json:"Facility,omitempty"`
	Geometry            *Geometry  `json:"Geometry,omitempty"`
	IconID              *string    `json:"IconId,omitempty"`
	ID                  *string    `json:"Id,omitempty"`
	LocationDescription *string    `json:"LocationDescription,omitempty"`
	ModifiedTime        *time.Time `json:"ModifiedTime,omitempty"`
	Name                *string    `json:"Name,omitempty"`
	OpenStatus          *string    `json:"OpenStatus,omitempty"`
	OperationStatus     *string    `json:"OperationStatus,omitempty"`
	Operator            *struct {
		Contact                *string `json:"Contact,omitempty"`
		ContactEmail           *string `json:"ContactEmail,omitempty"`
		ContactTelephoneNumber *string `json:"ContactTelephoneNumber,omitempty"`
		Name                   *string `json:"Name,omitempty"`
	} `json:"Operator,omitempty"`
	ParkingAccess []Geometry `json:"ParkingAccess,omitempty"`
	Photo         []struct {
		Title *string `json:"Title,omitempty"`
		URL   *string `json:"Url,omitempty"`
	} `json:"Photo,omitempty"`
	TariffsAndPayment *struct {
		FreeOfCharge *bool   `json:"FreeOfCharge,omitempty"`
		Tariff       *string `json:"Tariff,omitempty"`
	} `json:"TariffsAndPayment,omitempty"`
	UsageSenario           []string `json:"UsageSenario,omitempty"`
	VehicleCharacteristics []struct {
		LoadType       *string  `json:"LoadType,omitempty"`
		NumberOfSpaces *int     `json:"NumberOfSpaces,omitempty"`
		VehicleType    *Vehicle `json:"VehicleType,omitempty"`
	} `json:"VehicleCharacteristics,omitempty"`
}

type PavementData1Dot0 ¶ added in v0.3.0

type PavementData1Dot0 struct {
	BallMillValue *float64 `json:"BallMillValue,omitempty"`
	Binder        *string  `json:"Binder,omitempty"`
	Contractor    *string  `json:"Contractor,omitempty"`
	County        *County  `json:"County,omitempty"`
	Coverage      *string  `json:"Coverage,omitempty"`
	Deleted       *bool    `json:"Deleted,omitempty"`
	Direction     *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"Direction,omitempty"`
	EndContinuousLength   *int       `json:"EndContinuousLength,omitempty"`
	FinalInspectionDate   *time.Time `json:"FinalInspectionDate,omitempty"`
	Lane                  *int       `json:"Lane,omitempty"`
	Length                *int       `json:"Length,omitempty"`
	ManufacturingMethod   *string    `json:"ManufacturingMethod,omitempty"`
	MaxStoneSize          *int       `json:"MaxStoneSize,omitempty"`
	ModifiedTime          *time.Time `json:"ModifiedTime,omitempty"`
	PavementDate          *time.Time `json:"PavementDate,omitempty"`
	PavementType          *string    `json:"PavementType,omitempty"`
	PavingMethod          *string    `json:"PavingMethod,omitempty"`
	RoadMainNumber        *int       `json:"RoadMainNumber,omitempty"`
	RoadSubNumber         *int       `json:"RoadSubNumber,omitempty"`
	StartContinuousLength *int       `json:"StartContinuousLength,omitempty"`
	Thickness             *float64   `json:"Thickness,omitempty"`
	Timestamp             *time.Time `json:"TimeStamp,omitempty"`
	TreatmentCategory     *string    `json:"TreatmentCategory,omitempty"`
	Warranty              *int       `json:"Warranty,omitempty"`
	WarrantyIsDue         *time.Time `json:"WarrantyIsDue,omitempty"`
}

type PrecipitationAmount ¶ added in v0.3.0

type PrecipitationAmount string
const (
	PrecipitationDataMissing PrecipitationAmount = "Givare saknas/Fel pĂĄ givare"
	PrecipitationLightRain   PrecipitationAmount = "Lätt regn"
	PrecipitationMildRain    PrecipitationAmount = "MĂĄttligt regn"
	PrecipitationHeavyRain   PrecipitationAmount = "Kraftigt regn"

	PrecipitationLightSleet PrecipitationAmount = "Lätt snöblandat regn"
	PrecipitationMildSleet  PrecipitationAmount = "Måttligt snöblandat regn"
	PrecipitationHeavySleet PrecipitationAmount = "Kraftigt snöblandat regn"

	PrecipitationLightSnow PrecipitationAmount = "Lätt snöfall"
	PrecipitationMildSnow  PrecipitationAmount = "Måttligt snöfall"
	PrecipitationHeavySnow PrecipitationAmount = "Kraftigt snöfall"

	PrecipitationOther   PrecipitationAmount = "Annan nederbördstyp"
	PrecipitationUnknown PrecipitationAmount = "Okänd nederbördstyp"
	PrecipitationNone    PrecipitationAmount = "Ingen nederbörd"
)

type PrecipitationType ¶ added in v0.2.0

type PrecipitationType string
const (
	PrecipitationTypeDrizzle      PrecipitationType = "Duggregn"
	PrecipitationTypeHail         PrecipitationType = "Hagel"
	PrecipitationTypeRain         PrecipitationType = "Regn"
	PrecipitationTypeSnow         PrecipitationType = "Snö"
	PrecipitationTypeSleet        PrecipitationType = "Snöblandat regn"
	PrecipitationTypeFreezingRain PrecipitationType = "Underkylt regn"
	PrecipitationTypeNone         PrecipitationType = "Ingen nederbörd"
)

type PrecipitationTypeMeasure ¶ added in v0.4.0

type PrecipitationTypeMeasure string
const (
	PrecipitationTypeMeasureYes PrecipitationTypeMeasure = "yes"
	PrecipitationTypeMeasureNo  PrecipitationTypeMeasure = "no"

	PrecipitationTypeMeasureRain         PrecipitationTypeMeasure = "rain"
	PrecipitationTypeMeasureFreezingRain PrecipitationTypeMeasure = "freezing_rain"
	PrecipitationTypeMeasureSnow         PrecipitationTypeMeasure = "snow"
	PrecipitationTypeMeasureSleet        PrecipitationTypeMeasure = "sleet"
)

type Query ¶

type Query struct {
	// contains filtered or unexported fields
}

Query is used to request information from the Trafikinfo API

func NewQuery ¶

func NewQuery(objectType ObjectType, schemaVersion float64) *Query

NewQuery returns a query that other methods can be chained on to further customise the request.

func (*Query) ChangeID ¶ added in v0.1.1

func (q *Query) ChangeID(opt string) *Query

ChangeID sets the change ID for the request. This should initially be 0 to request all data, and then be set to the value of the change ID in the response to only get updated/deleted objects since the previous change ID.

func (*Query) Distinct ¶

func (q *Query) Distinct(field string) *Query

Distinct returns an array of unique values of this field

func (*Query) Eval ¶ added in v0.3.0

func (q *Query) Eval(evaluations ...Evaluation) *Query

func (*Query) Exclude ¶

func (q *Query) Exclude(fields ...string) *Query

Exclude ensures element matching the specifields fields are omitted

func (*Query) Filter ¶

func (q *Query) Filter(filters ...Filter) *Query

func (*Query) ID ¶ added in v0.1.1

func (q *Query) ID(opt string) *Query

ID is an arbitrary value which will be echoed in the response. It can be used to associate queries with responses, especially when a request includes multiple queries.

func (*Query) Include ¶

func (q *Query) Include(fields ...string) *Query

Include ensures only elements matching the specified fields are returned

func (*Query) IncludeDeletedObjects ¶ added in v0.1.1

func (q *Query) IncludeDeletedObjects(opt bool) *Query

IncludeDeletedObjects requests that deleted objects also be returned. This defaults to false.

func (*Query) LastModified ¶ added in v0.1.1

func (q *Query) LastModified(opt bool) *Query

LastModified results in a lastmodified timestamp being included in the response.

func (*Query) Limit ¶ added in v0.1.1

func (q *Query) Limit(opt int) *Query

Limit sets the limit for the amount of items to be returned. This can be used together with Skip to implement pagination. A Limit of 0 means no limit at all, i.e return everything.

func (*Query) MarshalXML ¶

func (q *Query) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*Query) OrderBy ¶ added in v0.1.1

func (q *Query) OrderBy(opt string) *Query

OrderBy takes a sorting expression the items in the response will be sorted by.

For example:

OrderBy("SomeData.Name desc, SomeData.Description asc")

func (*Query) SSEURL ¶ added in v0.3.2

func (q *Query) SSEURL(opt bool) *Query

func (*Query) Skip ¶ added in v0.1.1

func (q *Query) Skip(opt int) *Query

Skip sets how many items to skip/exclude from the response. This can be used together with Limit to implement pagination.

type RailCrossing1Dot4 ¶ added in v0.2.0

type RailCrossing1Dot4 struct {
	DataLastUpdated        *time.Time `json:"DataLastUpdated,omitempty"`
	Deleted                *bool      `json:"Deleted,omitempty"`
	Geometry               *Geometry  `json:"Geometry,omitempty"`
	Kilometer              *int       `json:"Kilometer,omitempty"`
	LevelCrossingID        *int       `json:"LevelCrossingId,omitempty"`
	Meter                  *int       `json:"Meter,omitempty"`
	ModifiedTime           *time.Time `json:"ModifiedTime,omitempty"`
	NumberOfTracks         *int       `json:"NumberOfTracks,omitempty"`
	ObjectID               *int       `json:"ObjectId,omitempty"`
	OperatingMode          *string    `json:"OperatingMode,omitempty"`
	PortalHeightLeft       *float64   `json:"PortalHeightLeft,omitempty"`
	PortalHeightRight      *float64   `json:"PortalHeightRight,omitempty"`
	RailwayRouteID         *string    `json:"RailwayRouteId,omitempty"`
	RoadNameAlternative    *string    `json:"RoadNameAlternative,omitempty"`
	RoadNameOfficial       *string    `json:"RoadNameOfficial,omitempty"`
	RoadProfileCrest       *int       `json:"RoadProfileCrest,omitempty"`
	RoadProfileCrossCurve  *int       `json:"RoadProfileCrossCurve,omitempty"`
	RoadProfileSteepSlope  *int       `json:"RoadProfileSteepSlope,omitempty"`
	RoadProtectionAddition []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"RoadProtectionAddition,omitempty"`
	RoadProtectionBase []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"RoadProtectionBase,omitempty"`
	RoadRouteID  *string `json:"RoadRouteId,omitempty"`
	TrackPortion *int    `json:"TrackPortion,omitempty"`
	TrainFlow    *int    `json:"TrainFlow,omitempty"`
}

type RailCrossing1Dot5 ¶ added in v0.2.0

type RailCrossing1Dot5 struct {
	DataLastUpdated        *time.Time `json:"DataLastUpdated,omitempty"`
	Deleted                *bool      `json:"Deleted,omitempty"`
	Geometry               *Geometry  `json:"Geometry,omitempty"`
	Kilometer              *int       `json:"Kilometer,omitempty"`
	LevelCrossingID        *int       `json:"LevelCrossingId,omitempty"`
	Meter                  *int       `json:"Meter,omitempty"`
	ModifiedTime           *time.Time `json:"ModifiedTime,omitempty"`
	NumberOfTracks         *int       `json:"NumberOfTracks,omitempty"`
	OperatingMode          *string    `json:"OperatingMode,omitempty"`
	PortalHeightLeft       *float64   `json:"PortalHeightLeft,omitempty"`
	PortalHeightRight      *float64   `json:"PortalHeightRight,omitempty"`
	RailwayRouteID         *string    `json:"RailwayRouteId,omitempty"`
	RoadNameAlternative    *string    `json:"RoadNameAlternative,omitempty"`
	RoadNameOfficial       *string    `json:"RoadNameOfficial,omitempty"`
	RoadProfileCrest       *int       `json:"RoadProfileCrest,omitempty"`
	RoadProfileCrossCurve  *int       `json:"RoadProfileCrossCurve,omitempty"`
	RoadProfileSteepSlope  *int       `json:"RoadProfileSteepSlope,omitempty"`
	RoadProtectionAddition []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"RoadProtectionAddition,omitempty"`
	RoadProtectionBase []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"RoadProtectionBase,omitempty"`
	RoadRouteID  *string `json:"RoadRouteId,omitempty"`
	TrackPortion *int    `json:"TrackPortion,omitempty"`
	TrainFlow    *int    `json:"TrainFlow,omitempty"`
}

type ReasonCode1Dot0 ¶ added in v0.2.0

type ReasonCode1Dot0 struct {
	Code              *string    `json:"Code,omitempty"`
	Deleted           *bool      `json:"Deleted,omitempty"`
	GroupDescription  *string    `json:"GroupDescription,omitempty"`
	Level1Description *string    `json:"Level1Description,omitempty"`
	Level2Description *string    `json:"Level2Description,omitempty"`
	Level3Description *string    `json:"Level3Description,omitempty"`
	ModifiedTime      *time.Time `json:"ModifiedTime,omitempty"`
}

ReasonCode1Dot0 represents a reason for a train related issue.

The "Code" and "Level3Description" fields correspond to the "Code" and "Description" fields for the TrainAnnouncement and TrainMessage object types.

type Region ¶ added in v0.3.0

type Region uint

Region is the code for a region in Sweden

const (
	RegionNorth Region = iota + 1
	RegionMiddle
	RegionEast
	RegionStockholm
	RegionWest
	RegionSouth
)

func (Region) String ¶ added in v0.3.0

func (r Region) String() string

type Request ¶

type Request struct {
	XMLName string   `xml:"REQUEST"`
	Login   *login   `xml:"LOGIN"`
	Queries []*Query `xml:"QUERY"`
}

Request tells the API what we're interested in

It must include the Login information and at least one Query.

func NewRequest ¶

func NewRequest() *Request

NewRequest returns a Request using the specified API authentication key and the data to be retrieved and filtered by the specified queries. At least 1 query needs to be provided.

func (*Request) APIKey ¶

func (r *Request) APIKey(key string) *Request

APIKey sets the API key to use for this request

func (*Request) Build ¶

func (r *Request) Build() ([]byte, error)

Build returns the XML encoded request as an array of bytes. It can be passed as http.NewRequest's body by wrapping it in a call to bytes.NewBuffer().

The Build() method is final when used in a fluent API style, you can't chain additional methods on it that continue to modify the request.

func (*Request) Query ¶

func (r *Request) Query(query *Query, rest ...*Query) *Request

Query adds one or more queries to the request

type RoadCondition1Dot0 ¶ added in v0.3.0

type RoadCondition1Dot0 struct {
	Cause             []Cause       `json:"Cause,omitempty"`
	ConditionCode     *Condition    `json:"ConditionCode,omitempty"`
	ConditionInfo     []string      `json:"ConditionInfo,omitempty"`
	ConditionText     *string       `json:"ConditionText,omitempty"`
	County            []County      `json:"CountyNo,omitempty"`
	Creator           *string       `json:"Creator,omitempty"`
	Deleted           *bool         `json:"Deleted,omitempty"`
	EndTime           *time.Time    `json:"EndTime,omitempty"`
	Geometry          *Geometry     `json:"Geometry,omitempty"`
	IconID            *string       `json:"IconId,omitempty"`
	ID                *string       `json:"Id,omitempty"`
	LocationText      *string       `json:"LocationText,omitempty"`
	Measurement       []Measurement `json:"Measurement,omitempty"`
	ModifiedTime      *time.Time    `json:"ModifiedTime,omitempty"`
	RoadNumber        *string       `json:"RoadNumber,omitempty"`
	RoadNumberNumeric *int          `json:"RoadNumberNumeric,omitempty"`
	StartTime         *time.Time    `json:"StartTime,omitempty"`
	Warning           []Warning     `json:"Warning,omitempty"`
}

type RoadCondition1Dot1 ¶ added in v0.3.0

type RoadCondition1Dot1 struct {
	Cause                []Cause       `json:"Cause,omitempty"`
	ConditionCode        *Condition    `json:"ConditionCode,omitempty"`
	ConditionInfo        []string      `json:"ConditionInfo,omitempty"`
	ConditionText        *string       `json:"ConditionText,omitempty"`
	County               []County      `json:"CountyNo,omitempty"`
	Creator              *string       `json:"Creator,omitempty"`
	Deleted              *bool         `json:"Deleted,omitempty"`
	EndTime              *time.Time    `json:"EndTime,omitempty"`
	Geometry             *Geometry     `json:"Geometry,omitempty"`
	IconID               *string       `json:"IconId,omitempty"`
	ID                   *string       `json:"Id,omitempty"`
	LocationText         *string       `json:"LocationText,omitempty"`
	Measurement          []Measurement `json:"Measurement,omitempty"`
	ModifiedTime         *time.Time    `json:"ModifiedTime,omitempty"`
	RoadNumber           *string       `json:"RoadNumber,omitempty"`
	RoadNumberNumeric    *int          `json:"RoadNumberNumeric,omitempty"`
	SafetyRelatedMessage *bool         `json:"SafetyRelatedMessage,omitempty"`
	StartTime            *time.Time    `json:"StartTime,omitempty"`
	Warning              []Warning     `json:"Warning,omitempty"`
}

type RoadCondition1Dot2 ¶ added in v0.3.0

type RoadCondition1Dot2 struct {
	Cause                []Cause          `json:"Cause,omitempty"`
	ConditionCode        *Condition       `json:"ConditionCode,omitempty"`
	ConditionInfo        []string         `json:"ConditionInfo,omitempty"`
	ConditionText        *string          `json:"ConditionText,omitempty"`
	County               []County         `json:"CountyNo,omitempty"`
	Creator              *string          `json:"Creator,omitempty"`
	Deleted              *bool            `json:"Deleted,omitempty"`
	EndTime              *time.Time       `json:"EndTime,omitempty"`
	Geometry             *GeometryWithMod `json:"Geometry,omitempty"`
	IconID               *string          `json:"IconId,omitempty"`
	ID                   *string          `json:"Id,omitempty"`
	LocationText         *string          `json:"LocationText,omitempty"`
	Measurement          []Measurement    `json:"Measurement,omitempty"`
	ModifiedTime         *time.Time       `json:"ModifiedTime,omitempty"`
	RoadNumber           *string          `json:"RoadNumber,omitempty"`
	RoadNumberNumeric    *int             `json:"RoadNumberNumeric,omitempty"`
	SafetyRelatedMessage *bool            `json:"SafetyRelatedMessage,omitempty"`
	StartTime            *time.Time       `json:"StartTime,omitempty"`
	Warning              []Warning        `json:"Warning,omitempty"`
}

type RoadConditionOverview1Dot0 ¶ added in v0.3.0

type RoadConditionOverview1Dot0 struct {
	County                  []County   `json:"CountyNo,omitempty"`
	Deleted                 *bool      `json:"Deleted,omitempty"`
	EndTime                 *time.Time `json:"EndTime,omitempty"`
	Geometry                *Geometry  `json:"Geometry,omitempty"`
	ID                      *string    `json:"Id,omitempty"`
	LocationText            *string    `json:"LocationText,omitempty"`
	ModifiedTime            *time.Time `json:"ModifiedTime,omitempty"`
	StartTime               *time.Time `json:"StartTime,omitempty"`
	Text                    *string    `json:"Text,omitempty"`
	ValidUntilFurtherNotice *bool      `json:"ValidUntilFurtherNotice,omitempty"`
}

type RoadData1Dot0 ¶ added in v0.3.0

type RoadData1Dot0 struct {
	AADT                  *int `json:"AADT,omitempty"`
	AADTHeavyVehicles     *int `json:"AADTHeavyVehicles,omitempty"`
	AADTMeasurementMethod *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"AADTMeasurementMethod,omitempty"`
	AADTMeasurementYear *int `json:"AADTMeasurementYear,omitempty"`
	BearingCapacity     *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"BearingCapacity,omitempty"`
	County    *County `json:"County,omitempty"`
	Deleted   *bool   `json:"Deleted,omitempty"`
	Direction *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"Direction,omitempty"`
	EndContinuousLength *int       `json:"EndContinuousLength,omitempty"`
	LaneDescription     *int       `json:"LaneDescription,omitempty"`
	Length              *int       `json:"Length,omitempty"`
	ModifiedTime        *time.Time `json:"ModifiedTime,omitempty"`
	RoadCategory        *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"RoadCategory,omitempty"`
	RoadConstruction2009 *int `json:"RoadConstruction2009,omitempty"`
	RoadMainNumber       *int `json:"RoadMainNumber,omitempty"`
	RoadOwner            *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"RoadOwner,omitempty"`
	RoadSubNumber *int `json:"RoadSubNumber,omitempty"`
	RoadType      *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"RoadType,omitempty"`
	RoadWidth             *float64   `json:"RoadWidth,omitempty"`
	SpeedLimit            *int       `json:"SpeedLimit,omitempty"`
	StartContinuousLength *int       `json:"StartContinuousLength,omitempty"`
	Timestamp             *time.Time `json:"TimeStamp,omitempty"`
	WearLayer             *int       `json:"WearLayer,omitempty"`
	Winter2003            *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"Winter2003,omitempty"`
}

type RoadGeometry1Dot0 ¶ added in v0.3.0

type RoadGeometry1Dot0 struct {
	County    *County `json:"County,omitempty"`
	Deleted   *bool   `json:"Deleted,omitempty"`
	Direction *struct {
		Code  *int    `json:"Code,omitempty"`
		Value *string `json:"Value,omitempty"`
	} `json:"Direction,omitempty"`
	Geometry       *Geometry  `json:"Geometry,omitempty"`
	Length         *int       `json:"Length,omitempty"`
	ModifiedTime   *time.Time `json:"ModifiedTime,omitempty"`
	RoadMainNumber *int       `json:"RoadMainNumber,omitempty"`
	RoadSubNumber  *int       `json:"RoadSubNumber,omitempty"`
	Timestamp      *time.Time `json:"TimeStamp,omitempty"`
}

type Severity ¶ added in v0.4.2

type Severity string
const (
	SeverityNoImpact      Severity = "Ingen pĂĄverkan"
	SeveritySmallImpact   Severity = "Liten pĂĄverkan"
	SeverityBigImpact     Severity = "Stor pĂĄverkan"
	SeverityVeryBigImpact Severity = "Mycket stor pĂĄverkan"
)

type Situation1Dot0 ¶ added in v0.4.2

type Situation1Dot0 struct {
	CountryCode *Country `json:"CountryCode,omitempty"`
	Deleted     *bool    `json:"Deleted,omitempty"`
	Deviation   []struct {
		CountyNo     []County   `json:"CountyNo,omitempty"`
		CreationTime *time.Time `json:"CreationTime,omitempty"`
		Creator      *string    `json:"Creator,omitempty"`
		EndTime      *time.Time `json:"EndTime,omitempty"`
		Geometry     *Geometry  `json:"Geometry,omitempty"`
		Header       *string    `json:"Header,omitempty"`
		IconID       *string    `json:"IconId,omitempty"`
		ID           *string    `json:"Id,omitempty"`
		Image        []struct {
			HasFullSizePhoto *bool   `json:"HasFullSizePhoto,omitempty"`
			URL              *string `json:"Url,omitempty"`
		} `json:"Image,omitempty"`
		JourneyReference        *string      `json:"JourneyReference,omitempty"`
		LocationDescriptor      *string      `json:"LocationDescriptor,omitempty"`
		ManagedCause            *bool        `json:"ManagedCause,omitempty"`
		Message                 *string      `json:"Message,omitempty"`
		MessageCode             *string      `json:"MessageCode,omitempty"`
		MessageType             *MessageType `json:"MessageType,omitempty"`
		NumberOfLanesRestricted *int         `json:"NumberOfLanesRestricted,omitempty"`
		PositionalDescription   *string      `json:"PositionalDescription,omitempty"`
		RoadNumber              *string      `json:"RoadNumber,omitempty"`
		RoadNumberNumeric       *int         `json:"RoadNumberNumeric,omitempty"`
		Schedule                []struct {
			EndOfPeriod              *time.Time `json:"EndOfPeriod,omitempty"`
			RecurringTimePeriodOfDay []struct {
				End   *string `json:"End,omitempty"`
				Start *string `json:"Start,omitempty"`
			} `json:"RecurringTimePeriodOfDay,omitempty"`
			StartOfPeriod *time.Time `json:"StartOfPeriod,omitempty"`
		} `json:"Schedule,omitempty"`
		SeverityCode            *int       `json:"SeverityCode,omitempty"`
		SeverityText            *Severity  `json:"SeverityText,omitempty"`
		StartTime               *time.Time `json:"StartTime,omitempty"`
		TemporaryLimit          *string    `json:"TemporaryLimit,omitempty"`
		TrafficRestrictionType  *string    `json:"TrafficRestrictionType,omitempty"`
		ValidUntilFurtherNotice *bool      `json:"ValidUntilFurtherNotice,omitempty"`
	} `json:"Deviation,omitempty"`
	ID              *string    `json:"Id,omitempty"`
	ModifiedTime    *time.Time `json:"ModifiedTime,omitempty"`
	PublicationTime *time.Time `json:"PublicationTime,omitempty"`
}

type Situation1Dot1 ¶ added in v0.4.2

type Situation1Dot1 struct {
	CountryCode *Country `json:"CountryCode,omitempty"`
	Deleted     *bool    `json:"Deleted,omitempty"`
	Deviation   []struct {
		CountyNo     []County   `json:"CountyNo,omitempty"`
		CreationTime *time.Time `json:"CreationTime,omitempty"`
		Creator      *string    `json:"Creator,omitempty"`
		EndTime      *time.Time `json:"EndTime,omitempty"`
		Geometry     *Geometry  `json:"Geometry,omitempty"`
		Header       *string    `json:"Header,omitempty"`
		IconID       *string    `json:"IconId,omitempty"`
		ID           *string    `json:"Id,omitempty"`
		Image        []struct {
			HasFullSizePhoto *bool   `json:"HasFullSizePhoto,omitempty"`
			URL              *string `json:"Url,omitempty"`
		} `json:"Image,omitempty"`
		JourneyReference        *string      `json:"JourneyReference,omitempty"`
		LocationDescriptor      *string      `json:"LocationDescriptor,omitempty"`
		ManagedCause            *bool        `json:"ManagedCause,omitempty"`
		Message                 *string      `json:"Message,omitempty"`
		MessageCode             *string      `json:"MessageCode,omitempty"`
		MessageCodeValue        *string      `json:"MessageCodeValue,omitempty"`
		MessageType             *MessageType `json:"MessageType,omitempty"`
		MessageTypeValue        *string      `json:"MessageTypeValue,omitempty"`
		NumberOfLanesRestricted *int         `json:"NumberOfLanesRestricted,omitempty"`
		PositionalDescription   *string      `json:"PositionalDescription,omitempty"`
		RoadNumber              *string      `json:"RoadNumber,omitempty"`
		RoadNumberNumeric       *int         `json:"RoadNumberNumeric,omitempty"`
		SafetyRelatedMessage    *bool        `json:"SafetyRelatedMessage,omitempty"`
		Schedule                []struct {
			EndOfPeriod              *time.Time `json:"EndOfPeriod,omitempty"`
			RecurringTimePeriodOfDay []struct {
				End   *string `json:"End,omitempty"`
				Start *string `json:"Start,omitempty"`
			} `json:"RecurringTimePeriodOfDay,omitempty"`
			StartOfPeriod *time.Time `json:"StartOfPeriod,omitempty"`
		} `json:"Schedule,omitempty"`
		SeverityCode            *int       `json:"SeverityCode,omitempty"`
		SeverityText            *Severity  `json:"SeverityText,omitempty"`
		StartTime               *time.Time `json:"StartTime,omitempty"`
		TemporaryLimit          *string    `json:"TemporaryLimit,omitempty"`
		TrafficRestrictionType  *string    `json:"TrafficRestrictionType,omitempty"`
		ValidUntilFurtherNotice *bool      `json:"ValidUntilFurtherNotice,omitempty"`
		VersionTime             *time.Time `json:"VersionTime,omitempty"`
	} `json:"Deviation,omitempty"`
	ID              *string    `json:"Id,omitempty"`
	ModifiedTime    *time.Time `json:"ModifiedTime,omitempty"`
	PublicationTime *time.Time `json:"PublicationTime,omitempty"`
	VersionTime     *time.Time `json:"VersionTime,omitempty"`
}

type Situation1Dot2 ¶ added in v0.4.2

type Situation1Dot2 struct {
	CountryCode *Country `json:"CountryCode,omitempty"`
	Deleted     *bool    `json:"Deleted,omitempty"`
	Deviation   []struct {
		CountyNo     []County   `json:"CountyNo,omitempty"`
		CreationTime *time.Time `json:"CreationTime,omitempty"`
		Creator      *string    `json:"Creator,omitempty"`
		EndTime      *time.Time `json:"EndTime,omitempty"`
		Geometry     *Geometry  `json:"Geometry,omitempty"`
		Header       *string    `json:"Header,omitempty"`
		IconID       *string    `json:"IconId,omitempty"`
		ID           *string    `json:"Id,omitempty"`
		Image        []struct {
			HasFullSizePhoto *bool   `json:"HasFullSizePhoto,omitempty"`
			URL              *string `json:"Url,omitempty"`
		} `json:"Image,omitempty"`
		JourneyReference        *string      `json:"JourneyReference,omitempty"`
		LocationDescriptor      *string      `json:"LocationDescriptor,omitempty"`
		ManagedCause            *bool        `json:"ManagedCause,omitempty"`
		Message                 *string      `json:"Message,omitempty"`
		MessageCode             *string      `json:"MessageCode,omitempty"`
		MessageCodeValue        *string      `json:"MessageCodeValue,omitempty"`
		MessageType             *MessageType `json:"MessageType,omitempty"`
		MessageTypeValue        *string      `json:"MessageTypeValue,omitempty"`
		NumberOfLanesRestricted *int         `json:"NumberOfLanesRestricted,omitempty"`
		PositionalDescription   *string      `json:"PositionalDescription,omitempty"`
		RoadNumber              *string      `json:"RoadNumber,omitempty"`
		RoadNumberNumeric       *int         `json:"RoadNumberNumeric,omitempty"`
		SafetyRelatedMessage    *bool        `json:"SafetyRelatedMessage,omitempty"`
		Schedule                []struct {
			EndOfPeriod              *time.Time `json:"EndOfPeriod,omitempty"`
			RecurringTimePeriodOfDay []struct {
				End   *string `json:"End,omitempty"`
				Start *string `json:"Start,omitempty"`
			} `json:"RecurringTimePeriodOfDay,omitempty"`
			StartOfPeriod *time.Time `json:"StartOfPeriod,omitempty"`
		} `json:"Schedule,omitempty"`
		SeverityCode            *int       `json:"SeverityCode,omitempty"`
		SeverityText            *Severity  `json:"SeverityText,omitempty"`
		StartTime               *time.Time `json:"StartTime,omitempty"`
		TemporaryLimit          *string    `json:"TemporaryLimit,omitempty"`
		TrafficRestrictionType  *string    `json:"TrafficRestrictionType,omitempty"`
		ValidUntilFurtherNotice *bool      `json:"ValidUntilFurtherNotice,omitempty"`
		VersionTime             *time.Time `json:"VersionTime,omitempty"`
		WebLink                 *string    `json:"WebLink,omitempty"`
	} `json:"Deviation,omitempty"`
	ID              *string    `json:"Id,omitempty"`
	ModifiedTime    *time.Time `json:"ModifiedTime,omitempty"`
	PublicationTime *time.Time `json:"PublicationTime,omitempty"`
	VersionTime     *time.Time `json:"VersionTime,omitempty"`
}

type Situation1Dot4 ¶ added in v0.4.2

type Situation1Dot4 struct {
	CountryCode *Country `json:"CountryCode,omitempty"`
	Deleted     *bool    `json:"Deleted,omitempty"`
	Deviation   []struct {
		AffectedDirection      *string            `json:"AffectedDirection,omitempty"`
		AffectedDirectionValue *AffectedDirection `json:"AffectedDirectionValue,omitempty"`
		CountyNo               []County           `json:"CountyNo,omitempty"`
		CreationTime           *time.Time         `json:"CreationTime,omitempty"`
		Creator                *string            `json:"Creator,omitempty"`
		EndTime                *time.Time         `json:"EndTime,omitempty"`
		Geometry               *struct {
			Line  *Geometry `json:"Line,omitempty"`
			Point *Geometry `json:"Point,omitempty"`
		} `json:"Geometry,omitempty"`
		Header *string `json:"Header,omitempty"`
		IconID *string `json:"IconId,omitempty"`
		ID     *string `json:"Id,omitempty"`
		Image  []struct {
			HasFullSizePhoto *bool   `json:"HasFullSizePhoto,omitempty"`
			URL              *string `json:"Url,omitempty"`
		} `json:"Image,omitempty"`
		JourneyReference        *string      `json:"JourneyReference,omitempty"`
		LocationDescriptor      *string      `json:"LocationDescriptor,omitempty"`
		ManagedCause            *bool        `json:"ManagedCause,omitempty"`
		Message                 *string      `json:"Message,omitempty"`
		MessageCode             *string      `json:"MessageCode,omitempty"`
		MessageCodeValue        *string      `json:"MessageCodeValue,omitempty"`
		MessageType             *MessageType `json:"MessageType,omitempty"`
		MessageTypeValue        *string      `json:"MessageTypeValue,omitempty"`
		NumberOfLanesRestricted *int         `json:"NumberOfLanesRestricted,omitempty"`
		PositionalDescription   *string      `json:"PositionalDescription,omitempty"`
		RoadNumber              *string      `json:"RoadNumber,omitempty"`
		RoadNumberNumeric       *int         `json:"RoadNumberNumeric,omitempty"`
		SafetyRelatedMessage    *bool        `json:"SafetyRelatedMessage,omitempty"`
		Schedule                []struct {
			EndOfPeriod              *time.Time `json:"EndOfPeriod,omitempty"`
			RecurringTimePeriodOfDay []struct {
				End   *string `json:"End,omitempty"`
				Start *string `json:"Start,omitempty"`
			} `json:"RecurringTimePeriodOfDay,omitempty"`
			StartOfPeriod *time.Time `json:"StartOfPeriod,omitempty"`
		} `json:"Schedule,omitempty"`
		SeverityCode            *int       `json:"SeverityCode,omitempty"`
		SeverityText            *Severity  `json:"SeverityText,omitempty"`
		StartTime               *time.Time `json:"StartTime,omitempty"`
		TemporaryLimit          *string    `json:"TemporaryLimit,omitempty"`
		TrafficRestrictionType  *string    `json:"TrafficRestrictionType,omitempty"`
		ValidUntilFurtherNotice *bool      `json:"ValidUntilFurtherNotice,omitempty"`
		VersionTime             *time.Time `json:"VersionTime,omitempty"`
		WebLink                 *string    `json:"WebLink,omitempty"`
	} `json:"Deviation,omitempty"`
	ID              *string    `json:"Id,omitempty"`
	ModifiedTime    *time.Time `json:"ModifiedTime,omitempty"`
	PublicationTime *time.Time `json:"PublicationTime,omitempty"`
	VersionTime     *time.Time `json:"VersionTime,omitempty"`
}

type Situation1Dot5 ¶ added in v0.4.2

type Situation1Dot5 struct {
	CountryCode *Country `json:"CountryCode,omitempty"`
	Deleted     *bool    `json:"Deleted,omitempty"`
	Deviation   []struct {
		AffectedDirection      *string            `json:"AffectedDirection,omitempty"`
		AffectedDirectionValue *AffectedDirection `json:"AffectedDirectionValue,omitempty"`
		CountyNo               []County           `json:"CountyNo,omitempty"`
		CreationTime           *time.Time         `json:"CreationTime,omitempty"`
		Creator                *string            `json:"Creator,omitempty"`
		EndTime                *time.Time         `json:"EndTime,omitempty"`
		Geometry               *struct {
			Line  *Geometry `json:"Line,omitempty"`
			Point *Geometry `json:"Point,omitempty"`
		} `json:"Geometry,omitempty"`
		Header *string `json:"Header,omitempty"`
		IconID *string `json:"IconId,omitempty"`
		ID     *string `json:"Id,omitempty"`
		Image  []struct {
			HasFullSizePhoto *bool   `json:"HasFullSizePhoto,omitempty"`
			URL              *string `json:"Url,omitempty"`
		} `json:"Image,omitempty"`
		JourneyReference        *string      `json:"JourneyReference,omitempty"`
		LocationDescriptor      *string      `json:"LocationDescriptor,omitempty"`
		ManagedCause            *bool        `json:"ManagedCause,omitempty"`
		Message                 *string      `json:"Message,omitempty"`
		MessageCode             *string      `json:"MessageCode,omitempty"`
		MessageCodeValue        *string      `json:"MessageCodeValue,omitempty"`
		MessageType             *MessageType `json:"MessageType,omitempty"`
		MessageTypeValue        *string      `json:"MessageTypeValue,omitempty"`
		NumberOfLanesRestricted *int         `json:"NumberOfLanesRestricted,omitempty"`
		PositionalDescription   *string      `json:"PositionalDescription,omitempty"`
		RoadName                *string      `json:"RoadName,omitempty"`
		RoadNumber              *string      `json:"RoadNumber,omitempty"`
		RoadNumberNumeric       *int         `json:"RoadNumberNumeric,omitempty"`
		SafetyRelatedMessage    *bool        `json:"SafetyRelatedMessage,omitempty"`
		Schedule                []struct {
			EndOfPeriod              *time.Time `json:"EndOfPeriod,omitempty"`
			RecurringTimePeriodOfDay []struct {
				End   *string `json:"End,omitempty"`
				Start *string `json:"Start,omitempty"`
			} `json:"RecurringTimePeriodOfDay,omitempty"`
			StartOfPeriod *time.Time `json:"StartOfPeriod,omitempty"`
		} `json:"Schedule,omitempty"`
		SeverityCode            *int       `json:"SeverityCode,omitempty"`
		SeverityText            *Severity  `json:"SeverityText,omitempty"`
		StartTime               *time.Time `json:"StartTime,omitempty"`
		TemporaryLimit          *string    `json:"TemporaryLimit,omitempty"`
		TrafficRestrictionType  *string    `json:"TrafficRestrictionType,omitempty"`
		ValidUntilFurtherNotice *bool      `json:"ValidUntilFurtherNotice,omitempty"`
		VersionTime             *time.Time `json:"VersionTime,omitempty"`
		WebLink                 *string    `json:"WebLink,omitempty"`
	} `json:"Deviation,omitempty"`
	ID              *string    `json:"Id,omitempty"`
	ModifiedTime    *time.Time `json:"ModifiedTime,omitempty"`
	PublicationTime *time.Time `json:"PublicationTime,omitempty"`
	VersionTime     *time.Time `json:"VersionTime,omitempty"`
}

type Status ¶ added in v0.3.0

type Status uint
const (
	StatusFreeAccess Status = iota + 1
	StatusPassabilityDifficult
	StatusPassabilityImpossile
	StatusPassabilityUnknown
)

func (Status) String ¶ added in v0.3.0

func (s Status) String() string

type StopType ¶ added in v0.3.0

type StopType string
const (
	StopTypeArrival          StopType = "Ank"
	StopTypeDeparture        StopType = "Avg"
	StopTypeArrivalDeparture StopType = "Ank/Avg"
)

type TrafficFlow1Dot0 ¶ added in v0.3.0

type TrafficFlow1Dot0 struct {
	AverageVehicleSpeed            *int       `json:"AverageVehicleSpeed,omitempty"`
	County                         []County   `json:"CountyNo,omitempty"`
	Deleted                        *bool      `json:"Deleted,omitempty"`
	Geometry                       *Geometry  `json:"Geometry,omitempty"`
	MeasurementOrCalculationPeriod *int       `json:"MeasurementOrCalculationPeriod,omitempty"`
	MeasurementSide                *string    `json:"MeasurementSide,omitempty"`
	MeasurementTime                *time.Time `json:"MeasurementTime,omitempty"`
	ModifiedTime                   *time.Time `json:"ModifiedTime,omitempty"`
	RegionID                       *Region    `json:"RegionId,omitempty"`
	SiteID                         *int       `json:"SiteId,omitempty"`
	SpecificLane                   *string    `json:"SpecificLane,omitempty"`
	VehicleFlowRate                *int       `json:"VehicleFlowRate,omitempty"`
	VehicleType                    *Vehicle   `json:"VehicleType,omitempty"`
}

type TrafficFlow1Dot4 ¶ added in v0.3.0

type TrafficFlow1Dot4 struct {
	AverageVehicleSpeed            *float64   `json:"AverageVehicleSpeed,omitempty"`
	County                         []County   `json:"CountyNo,omitempty"`
	Deleted                        *bool      `json:"Deleted,omitempty"`
	Geometry                       *Geometry  `json:"Geometry,omitempty"`
	MeasurementOrCalculationPeriod *int       `json:"MeasurementOrCalculationPeriod,omitempty"`
	MeasurementSide                *string    `json:"MeasurementSide,omitempty"`
	MeasurementTime                *time.Time `json:"MeasurementTime,omitempty"`
	ModifiedTime                   *time.Time `json:"ModifiedTime,omitempty"`
	RegionID                       *Region    `json:"RegionId,omitempty"`
	SiteID                         *int       `json:"SiteId,omitempty"`
	SpecificLane                   *string    `json:"SpecificLane,omitempty"`
	VehicleFlowRate                *int       `json:"VehicleFlowRate,omitempty"`
	VehicleType                    *Vehicle   `json:"VehicleType,omitempty"`
}

type TrafficSafetyCamera1Dot0 ¶ added in v0.3.0

type TrafficSafetyCamera1Dot0 struct {
	Bearing      *int       `json:"Bearing,omitempty"`
	County       []County   `json:"CountyNo,omitempty"`
	Deleted      *bool      `json:"Deleted,omitempty"`
	Geometry     *Geometry  `json:"Geometry,omitempty"`
	IconID       *string    `json:"IconId,omitempty"`
	ID           *string    `json:"Id,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	Name         *string    `json:"Name,omitempty"`
	RoadNumber   *string    `json:"RoadNumber,omitempty"`
}

type TrafficStatus ¶ added in v0.3.0

type TrafficStatus string
const (
	TrafficStatusFreeflow   TrafficStatus = "freeflow"
	TrafficStatusHeavy      TrafficStatus = "heavy"
	TrafficStatusCongested  TrafficStatus = "congested"
	TrafficStatusImpossible TrafficStatus = "impossible"
	TrafficStatusUnknown    TrafficStatus = "unknown"
)

type TrainAnnouncement1Dot0 ¶ added in v0.2.0

type TrainAnnouncement1Dot0 struct {
	ActivityID                 *string       `json:"ActivityId,omitempty"`
	ActivityType               *ActivityType `json:"ActivityType,omitempty"`
	Advertised                 *bool         `json:"Advertised,omitempty"`
	AdvertisedTimeAtLocation   *time.Time    `json:"AdvertisedTimeAtLocation,omitempty"`
	AdvertisedTrainID          *string       `json:"AdvertisedTrainIdent,omitempty"`
	Booking                    []string      `json:"Booking,omitempty"`
	Canceled                   *bool         `json:"Canceled,omitempty"`
	Deleted                    *bool         `json:"Deleted,omitempty"`
	Deviation                  []string      `json:"Deviation,omitempty"`
	EstimatedTimeAtLocation    *time.Time    `json:"EstimatedTimeAtLocation,omitempty"`
	EstimatedTimeIsPreliminary *bool         `json:"EstimatedTimeIsPreliminary,omitempty"`
	FromLocation               []string      `json:"FromLocation,omitempty"`
	InformationOwner           *string       `json:"InformationOwner,omitempty"`
	LocationSignature          *string       `json:"LocationSignature,omitempty"`
	MobileWebLink              *string       `json:"MobileWebLink,omitempty"`
	ModifiedTime               *time.Time    `json:"ModifiedTime,omitempty"`
	OtherInformation           []string      `json:"OtherInformation,omitempty"`
	ProductInformation         []string      `json:"ProductInformation,omitempty"`
	ScheduledDepartureDateTime *time.Time    `json:"ScheduledDepartureDateTime,omitempty"`
	Service                    []string      `json:"Service,omitempty"`
	TimeAtLocation             *time.Time    `json:"TimeAtLocation,omitempty"`
	ToLocation                 []string      `json:"ToLocation,omitempty"`
	TrackAtLocation            *string       `json:"TrackAtLocation,omitempty"`
	TrainComposition           []string      `json:"TrainComposition,omitempty"`
	TypeOfTraffic              *string       `json:"TypeOfTraffic,omitempty"`
	WebLink                    *string       `json:"WebLink,omitempty"`
}

type TrainAnnouncement1Dot3 ¶ added in v0.2.0

type TrainAnnouncement1Dot3 struct {
	ActivityID                 *string       `json:"ActivityId,omitempty"`
	ActivityType               *ActivityType `json:"ActivityType,omitempty"`
	Advertised                 *bool         `json:"Advertised,omitempty"`
	AdvertisedTimeAtLocation   *time.Time    `json:"AdvertisedTimeAtLocation,omitempty"`
	AdvertisedTrainID          *string       `json:"AdvertisedTrainIdent,omitempty"`
	Booking                    []string      `json:"Booking,omitempty"`
	Canceled                   *bool         `json:"Canceled,omitempty"`
	Deleted                    *bool         `json:"Deleted,omitempty"`
	Deviation                  []string      `json:"Deviation,omitempty"`
	EstimatedTimeAtLocation    *time.Time    `json:"EstimatedTimeAtLocation,omitempty"`
	EstimatedTimeIsPreliminary *bool         `json:"EstimatedTimeIsPreliminary,omitempty"`
	FromLocation               []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"FromLocation,omitempty"`
	InformationOwner                      *string    `json:"InformationOwner,omitempty"`
	LocationSignature                     *string    `json:"LocationSignature,omitempty"`
	MobileWebLink                         *string    `json:"MobileWebLink,omitempty"`
	ModifiedTime                          *time.Time `json:"ModifiedTime,omitempty"`
	NewEquipment                          *int       `json:"NewEquipment,omitempty"`
	OtherInformation                      []string   `json:"OtherInformation,omitempty"`
	PlannedEstimatedTimeAtLocation        *time.Time `json:"PlannedEstimatedTimeAtLocation,omitempty"`
	PlannedEstimatedTimeAtLocationIsValid *bool      `json:"PlannedEstimatedTimeAtLocationIsValid,omitempty"`
	ProductInformation                    []string   `json:"ProductInformation,omitempty"`
	ScheduledDepartureDateTime            *time.Time `json:"ScheduledDepartureDateTime,omitempty"`
	Service                               []string   `json:"Service,omitempty"`
	TechnicalTrainID                      *string    `json:"TechnicalTrainIdent,omitempty"`
	TimeAtLocation                        *time.Time `json:"TimeAtLocation,omitempty"`
	ToLocation                            []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ToLocation,omitempty"`
	TrackAtLocation  *string  `json:"TrackAtLocation,omitempty"`
	TrainComposition []string `json:"TrainComposition,omitempty"`
	TypeOfTraffic    *string  `json:"TypeOfTraffic,omitempty"`
	ViaFromLocation  []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaFromLocation,omitempty"`
	ViaToLocation []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaToLocation,omitempty"`
	WebLink     *string `json:"WebLink,omitempty"`
	WebLinkName *string `json:"WebLinkName,omitempty"`
}

type TrainAnnouncement1Dot4 ¶ added in v0.2.0

type TrainAnnouncement1Dot4 struct {
	ActivityID                 *string       `json:"ActivityId,omitempty"`
	ActivityType               *ActivityType `json:"ActivityType,omitempty"`
	Advertised                 *bool         `json:"Advertised,omitempty"`
	AdvertisedTimeAtLocation   *time.Time    `json:"AdvertisedTimeAtLocation,omitempty"`
	AdvertisedTrainID          *string       `json:"AdvertisedTrainIdent,omitempty"`
	Booking                    []string      `json:"Booking,omitempty"`
	Canceled                   *bool         `json:"Canceled,omitempty"`
	Deleted                    *bool         `json:"Deleted,omitempty"`
	Deviation                  []string      `json:"Deviation,omitempty"`
	EstimatedTimeAtLocation    *time.Time    `json:"EstimatedTimeAtLocation,omitempty"`
	EstimatedTimeIsPreliminary *bool         `json:"EstimatedTimeIsPreliminary,omitempty"`
	FromLocation               []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"FromLocation,omitempty"`
	InformationOwner                      *string    `json:"InformationOwner,omitempty"`
	LocationSignature                     *string    `json:"LocationSignature,omitempty"`
	MobileWebLink                         *string    `json:"MobileWebLink,omitempty"`
	ModifiedTime                          *time.Time `json:"ModifiedTime,omitempty"`
	NewEquipment                          *int       `json:"NewEquipment,omitempty"`
	Operator                              *string    `json:"Operator,omitempty"`
	OtherInformation                      []string   `json:"OtherInformation,omitempty"`
	PlannedEstimatedTimeAtLocation        *time.Time `json:"PlannedEstimatedTimeAtLocation,omitempty"`
	PlannedEstimatedTimeAtLocationIsValid *bool      `json:"PlannedEstimatedTimeAtLocationIsValid,omitempty"`
	ProductInformation                    []string   `json:"ProductInformation,omitempty"`
	ScheduledDepartureDateTime            *time.Time `json:"ScheduledDepartureDateTime,omitempty"`
	Service                               []string   `json:"Service,omitempty"`
	TechnicalDateTime                     *time.Time `json:"TechnicalDateTime,omitempty"`
	TechnicalTrainID                      *string    `json:"TechnicalTrainIdent,omitempty"`
	TimeAtLocation                        *time.Time `json:"TimeAtLocation,omitempty"`
	TimeAtLocationWithSeconds             *time.Time `json:"TimeAtLocationWithSeconds,omitempty"`
	ToLocation                            []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ToLocation,omitempty"`
	TrackAtLocation  *string  `json:"TrackAtLocation,omitempty"`
	TrainComposition []string `json:"TrainComposition,omitempty"`
	TrainOwner       *string  `json:"TrainOwner,omitempty"`
	TypeOfTraffic    *string  `json:"TypeOfTraffic,omitempty"`
	ViaFromLocation  []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaFromLocation,omitempty"`
	ViaToLocation []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaToLocation,omitempty"`
	WebLink     *string `json:"WebLink,omitempty"`
	WebLinkName *string `json:"WebLinkName,omitempty"`
}

type TrainAnnouncement1Dot5 ¶ added in v0.2.0

type TrainAnnouncement1Dot5 struct {
	ActivityID               *string       `json:"ActivityId,omitempty"`
	ActivityType             *ActivityType `json:"ActivityType,omitempty"`
	Advertised               *bool         `json:"Advertised,omitempty"`
	AdvertisedTimeAtLocation *time.Time    `json:"AdvertisedTimeAtLocation,omitempty"`
	AdvertisedTrainID        *string       `json:"AdvertisedTrainIdent,omitempty"`
	Booking                  []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"Booking,omitempty"`
	Canceled  *bool `json:"Canceled,omitempty"`
	Deleted   *bool `json:"Deleted,omitempty"`
	Deviation []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"Deviation,omitempty"`
	EstimatedTimeAtLocation    *time.Time `json:"EstimatedTimeAtLocation,omitempty"`
	EstimatedTimeIsPreliminary *bool      `json:"EstimatedTimeIsPreliminary,omitempty"`
	FromLocation               []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"FromLocation,omitempty"`
	InformationOwner  *string    `json:"InformationOwner,omitempty"`
	LocationSignature *string    `json:"LocationSignature,omitempty"`
	MobileWebLink     *string    `json:"MobileWebLink,omitempty"`
	ModifiedTime      *time.Time `json:"ModifiedTime,omitempty"`
	NewEquipment      *int       `json:"NewEquipment,omitempty"`
	Operator          *string    `json:"Operator,omitempty"`
	OtherInformation  []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"OtherInformation,omitempty"`
	PlannedEstimatedTimeAtLocation        *time.Time `json:"PlannedEstimatedTimeAtLocation,omitempty"`
	PlannedEstimatedTimeAtLocationIsValid *bool      `json:"PlannedEstimatedTimeAtLocationIsValid,omitempty"`
	ProductInformation                    []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"ProductInformation,omitempty"`
	ScheduledDepartureDateTime *time.Time `json:"ScheduledDepartureDateTime,omitempty"`
	Service                    []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"Service,omitempty"`
	TechnicalDateTime         *time.Time `json:"TechnicalDateTime,omitempty"`
	TechnicalTrainID          *string    `json:"TechnicalTrainIdent,omitempty"`
	TimeAtLocation            *time.Time `json:"TimeAtLocation,omitempty"`
	TimeAtLocationWithSeconds *time.Time `json:"TimeAtLocationWithSeconds,omitempty"`
	ToLocation                []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ToLocation,omitempty"`
	TrackAtLocation  *string `json:"TrackAtLocation,omitempty"`
	TrainComposition []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"TrainComposition,omitempty"`
	TrainOwner      *string `json:"TrainOwner,omitempty"`
	TypeOfTraffic   *string `json:"TypeOfTraffic,omitempty"`
	ViaFromLocation []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaFromLocation,omitempty"`
	ViaToLocation []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaToLocation,omitempty"`
	WebLink     *string `json:"WebLink,omitempty"`
	WebLinkName *string `json:"WebLinkName,omitempty"`
}

type TrainAnnouncement1Dot6 ¶ added in v0.2.0

type TrainAnnouncement1Dot6 struct {
	ActivityID               *string       `json:"ActivityId,omitempty"`
	ActivityType             *ActivityType `json:"ActivityType,omitempty"`
	Advertised               *bool         `json:"Advertised,omitempty"`
	AdvertisedTimeAtLocation *time.Time    `json:"AdvertisedTimeAtLocation,omitempty"`
	AdvertisedTrainID        *string       `json:"AdvertisedTrainIdent,omitempty"`
	Booking                  []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"Booking,omitempty"`
	Canceled  *bool `json:"Canceled,omitempty"`
	Deleted   *bool `json:"Deleted,omitempty"`
	Deviation []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"Deviation,omitempty"`
	EstimatedTimeAtLocation    *time.Time `json:"EstimatedTimeAtLocation,omitempty"`
	EstimatedTimeIsPreliminary *bool      `json:"EstimatedTimeIsPreliminary,omitempty"`
	FromLocation               []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"FromLocation,omitempty"`
	InformationOwner  *string    `json:"InformationOwner,omitempty"`
	LocationSignature *string    `json:"LocationSignature,omitempty"`
	MobileWebLink     *string    `json:"MobileWebLink,omitempty"`
	ModifiedTime      *time.Time `json:"ModifiedTime,omitempty"`
	NewEquipment      *int       `json:"NewEquipment,omitempty"`
	Operator          *string    `json:"Operator,omitempty"`
	OtherInformation  []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"OtherInformation,omitempty"`
	PlannedEstimatedTimeAtLocation        *time.Time `json:"PlannedEstimatedTimeAtLocation,omitempty"`
	PlannedEstimatedTimeAtLocationIsValid *bool      `json:"PlannedEstimatedTimeAtLocationIsValid,omitempty"`
	ProductInformation                    []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"ProductInformation,omitempty"`
	ScheduledDepartureDateTime *time.Time `json:"ScheduledDepartureDateTime,omitempty"`
	Service                    []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"Service,omitempty"`
	TechnicalDateTime         *time.Time `json:"TechnicalDateTime,omitempty"`
	TechnicalTrainID          *string    `json:"TechnicalTrainIdent,omitempty"`
	TimeAtLocation            *time.Time `json:"TimeAtLocation,omitempty"`
	TimeAtLocationWithSeconds *time.Time `json:"TimeAtLocationWithSeconds,omitempty"`
	ToLocation                []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ToLocation,omitempty"`
	TrackAtLocation  *string `json:"TrackAtLocation,omitempty"`
	TrainComposition []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"TrainComposition,omitempty"`
	TrainOwner    *string `json:"TrainOwner,omitempty"`
	TypeOfTraffic []struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"TypeOfTraffic,omitempty"`
	ViaFromLocation []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaFromLocation,omitempty"`
	ViaToLocation []struct {
		LocationName *string `json:"LocationName,omitempty"`
		Priority     *int    `json:"Priority,omitempty"`
		Order        *int    `json:"Order,omitempty"`
	} `json:"ViaToLocation,omitempty"`
	WebLink     *string `json:"WebLink,omitempty"`
	WebLinkName *string `json:"WebLinkName,omitempty"`
}

type TrainMessage1Dot0 ¶ added in v0.2.0

type TrainMessage1Dot0 struct {
	AffectedLocation    []string   `json:"AffectedLocation,omitempty"`
	County              []County   `json:"CountyNo,omitempty"`
	Deleted             *bool      `json:"Deleted,omitempty"`
	EventID             *string    `json:"EventId,omitempty"`
	ExternalDescription *string    `json:"ExternalDescription,omitempty"`
	Geometry            *Geometry  `json:"Geometry,omitempty"`
	LastUpdateDateTime  *time.Time `json:"LastUpdateDateTime,omitempty"`
	ModifiedTime        *time.Time `json:"ModifiedTime,omitempty"`
	StartDateTime       *time.Time `json:"StartDateTime,omitempty"`
	ReasonCodeText      *string    `json:"ReasonCodeText,omitempty"`
}

type TrainMessage1Dot3 ¶ added in v0.2.0

type TrainMessage1Dot3 struct {
	AffectedLocation    []string   `json:"AffectedLocation,omitempty"`
	County              []County   `json:"CountyNo,omitempty"`
	Deleted             *bool      `json:"Deleted,omitempty"`
	EndDateTime         *time.Time `json:"EndDateTime,omitempty"`
	EventID             *string    `json:"EventId,omitempty"`
	ExternalDescription *string    `json:"ExternalDescription,omitempty"`
	Geometry            *Geometry  `json:"Geometry,omitempty"`
	Header              *string    `json:"Header,omitempty"`
	LastUpdateDateTime  *time.Time `json:"LastUpdateDateTime,omitempty"`
	ModifiedTime        *time.Time `json:"ModifiedTime,omitempty"`
	ReasonCodeText      *string    `json:"ReasonCodeText,omitempty"`
	StartDateTime       *time.Time `json:"StartDateTime,omitempty"`
	TrafficImpact       *struct {
		AffectedLocation []string `json:"AffectedLocation,omitempty"`
		FromLocation     []string `json:"FromLocation,omitempty"`
		ToLocation       []string `json:"ToLocation,omitempty"`
	} `json:"TrafficImpact,omitempty"`
}

type TrainMessage1Dot4 ¶ added in v0.2.0

type TrainMessage1Dot4 struct {
	AffectedLocation                       []string   `json:"AffectedLocation,omitempty"`
	County                                 []County   `json:"CountyNo,omitempty"`
	Deleted                                *bool      `json:"Deleted,omitempty"`
	EndDateTime                            *time.Time `json:"EndDateTime,omitempty"`
	EventID                                *string    `json:"EventId,omitempty"`
	ExpectTrafficImpact                    *bool      `jsno:"ExpectTrafficImpact,omitempty"`
	ExternalDescription                    *string    `json:"ExternalDescription,omitempty"`
	Geometry                               *Geometry  `json:"Geometry,omitempty"`
	Header                                 *string    `json:"Header,omitempty"`
	LastUpdateDateTime                     *time.Time `json:"LastUpdateDateTime,omitempty"`
	ModifiedTime                           *time.Time `json:"ModifiedTime,omitempty"`
	PrognosticatedEndDateTimeTrafficImpact *time.Time `json:"PrognosticatedEndDateTimeTrafficImpact,omitempty"`
	ReasonCodeText                         *string    `json:"ReasonCodeText,omitempty"`
	StartDateTime                          *time.Time `json:"StartDateTime,omitempty"`
	TrafficImpact                          *struct {
		AffectedLocation []string `json:"AffectedLocation,omitempty"`
		FromLocation     []string `json:"FromLocation,omitempty"`
		ToLocation       []string `json:"ToLocation,omitempty"`
	} `json:"TrafficImpact,omitempty"`
}

type TrainMessage1Dot5 ¶ added in v0.2.0

type TrainMessage1Dot5 struct {
	AffectedLocation                       []string   `json:"AffectedLocation,omitempty"`
	County                                 []County   `json:"CountyNo,omitempty"`
	Deleted                                *bool      `json:"Deleted,omitempty"`
	EndDateTime                            *time.Time `json:"EndDateTime,omitempty"`
	EventID                                *string    `json:"EventId,omitempty"`
	ExpectTrafficImpact                    *bool      `jsno:"ExpectTrafficImpact,omitempty"`
	ExternalDescription                    *string    `json:"ExternalDescription,omitempty"`
	Geometry                               *Geometry  `json:"Geometry,omitempty"`
	Header                                 *string    `json:"Header,omitempty"`
	LastUpdateDateTime                     *time.Time `json:"LastUpdateDateTime,omitempty"`
	ModifiedTime                           *time.Time `json:"ModifiedTime,omitempty"`
	PrognosticatedEndDateTimeTrafficImpact *time.Time `json:"PrognosticatedEndDateTimeTrafficImpact,omitempty"`
	ReasonCode                             *struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"ReasonCodeText,omitempty"`
	StartDateTime *time.Time `json:"StartDateTime,omitempty"`
	TrafficImpact *struct {
		AffectedLocation []string `json:"AffectedLocation,omitempty"`
		FromLocation     []string `json:"FromLocation,omitempty"`
		ToLocation       []string `json:"ToLocation,omitempty"`
	} `json:"TrafficImpact,omitempty"`
}

type TrainMessage1Dot6 ¶ added in v0.2.0

type TrainMessage1Dot6 struct {
	County                                 []County   `json:"CountyNo,omitempty"`
	Deleted                                *bool      `json:"Deleted,omitempty"`
	EndDateTime                            *time.Time `json:"EndDateTime,omitempty"`
	EventID                                *string    `json:"EventId,omitempty"`
	ExternalDescription                    *string    `json:"ExternalDescription,omitempty"`
	Geometry                               *Geometry  `json:"Geometry,omitempty"`
	Header                                 *string    `json:"Header,omitempty"`
	LastUpdateDateTime                     *time.Time `json:"LastUpdateDateTime,omitempty"`
	ModifiedTime                           *time.Time `json:"ModifiedTime,omitempty"`
	PrognosticatedEndDateTimeTrafficImpact *time.Time `json:"PrognosticatedEndDateTimeTrafficImpact,omitempty"`
	ReasonCode                             *struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"ReasonCodeText,omitempty"`
	StartDateTime *time.Time `json:"StartDateTime,omitempty"`
	TrafficImpact *struct {
		AffectedLocation []string `json:"AffectedLocation,omitempty"`
		FromLocation     []string `json:"FromLocation,omitempty"`
		IsConfirmed      *bool    `json:"IsConfirmed,omitempty"`
		ToLocation       []string `json:"ToLocation,omitempty"`
	} `json:"TrafficImpact,omitempty"`
}

type TrainMessage1Dot7 ¶ added in v0.2.0

type TrainMessage1Dot7 struct {
	County                                 []County   `json:"CountyNo,omitempty"`
	Deleted                                *bool      `json:"Deleted,omitempty"`
	EndDateTime                            *time.Time `json:"EndDateTime,omitempty"`
	EventID                                *string    `json:"EventId,omitempty"`
	ExternalDescription                    *string    `json:"ExternalDescription,omitempty"`
	Geometry                               *Geometry  `json:"Geometry,omitempty"`
	Header                                 *string    `json:"Header,omitempty"`
	LastUpdateDateTime                     *time.Time `json:"LastUpdateDateTime,omitempty"`
	ModifiedTime                           *time.Time `json:"ModifiedTime,omitempty"`
	PrognosticatedEndDateTimeTrafficImpact *time.Time `json:"PrognosticatedEndDateTimeTrafficImpact,omitempty"`
	ReasonCode                             *struct {
		Code        *string `json:"Code,omitempty"`
		Description *string `json:"Description,omitempty"`
	} `json:"ReasonCodeText,omitempty"`
	StartDateTime *time.Time `json:"StartDateTime,omitempty"`
	TrafficImpact *struct {
		AffectedLocation []struct {
			LocationSignature       *string `json:"LocationSignature,omitempty"`
			ShouldBeTrafficInformed *bool   `json:"ShouldBeTrafficInformed,omitempty"`
		} `json:"AffectedLocation,omitempty"`
		FromLocation []string `json:"FromLocation,omitempty"`
		IsConfirmed  *bool    `json:"IsConfirmed,omitempty"`
		ToLocation   []string `json:"ToLocation,omitempty"`
	} `json:"TrafficImpact,omitempty"`
}

type TrainStation1Dot0 ¶ added in v0.2.0

type TrainStation1Dot0 struct {
	Advertised                  *bool      `json:"Advertised,omitempty"`
	AdvertisedLocationName      *string    `json:"AdvertisedLocationName,omitempty"`
	AdvertisedShortLocationName *string    `json:"AdvertisedShortLocationName,omitempty"`
	Country                     *Country   `json:"CountryCode,omitempty"`
	County                      []County   `json:"CountyNo,omitempty"`
	Deleted                     *bool      `json:"Deleted,omitempty"`
	Geometry                    *Geometry  `json:"Geometry,omitempty"`
	LocationInformationText     *string    `json:"LocationInformationText,omitempty"`
	LocationSignature           *string    `json:"LocationSignature,omitempty"`
	ModifiedTime                *time.Time `json:"ModifiedTime,omitempty"`
	PlatformLine                []string   `json:"PlatformLine,omitempty"`
	Prognosticated              *bool      `json:"Prognosticated,omitempty"`
}

type TrainStation1Dot4 ¶ added in v0.2.0

type TrainStation1Dot4 struct {
	Advertised                  *bool      `json:"Advertised,omitempty"`
	AdvertisedLocationName      *string    `json:"AdvertisedLocationName,omitempty"`
	AdvertisedShortLocationName *string    `json:"AdvertisedShortLocationName,omitempty"`
	Country                     *Country   `json:"CountryCode,omitempty"`
	County                      []County   `json:"CountyNo,omitempty"`
	Deleted                     *bool      `json:"Deleted,omitempty"`
	Geometry                    *Geometry  `json:"Geometry,omitempty"`
	LocationInformationText     *string    `json:"LocationInformationText,omitempty"`
	LocationSignature           *string    `json:"LocationSignature,omitempty"`
	ModifiedTime                *time.Time `json:"ModifiedTime,omitempty"`
	OfficialLocationName        *string    `json:"OfficialLocationName,omitempty"`
	PlatformLine                []string   `json:"PlatformLine,omitempty"`
	Prognosticated              *bool      `json:"Prognosticated,omitempty"`
}

type TrainStationMessage1Dot0 ¶ added in v0.2.0

type TrainStationMessage1Dot0 struct {
	ActiveDays        *string    `json:"ActiveDays,omitempty"`
	Deleted           *bool      `json:"Deleted,omitempty"`
	EndDateTime       *time.Time `json:"EndDateTime,omitempty"`
	EventID           *string    `json:"EventId,omitempty" yaml:"EventId,omitempty"`
	FreeText          *string    `json:"FreeText,omitempty"`
	ID                *string    `json:"Id,omitempty"`
	LocationCode      *string    `json:"LocationCode,omitempty"`
	MediaType         *MediaType `json:"MediaType,omitempty"`
	ModifiedTime      *time.Time `json:"ModifiedTime,omitempty"`
	MonitorAttributes *struct {
		BigScreenMonitorActivated *bool `json:"BigScreenMonitorActivated,omitempty"`
		CommuterMonitor           *bool `json:"CommuterMonitor,omitempty"`
	} `json:"MonitorAttributes,omitempty"`
	PlatformSignAttributes *struct {
		CommuterPlatformSign *bool `json:"CommuterPlatformSign,omitempty"`
		TrackList            *struct {
			Track []string `json:"Track,omitempty"`
		} `json:"TrackList,omitempty"`
	} `json:"PlatformSignAttributes,omitempty"`
	PublicAnnouncementAttributes *struct {
		EnglishPublicAnnouncementActivated *bool   `json:"EnglishPublicAnnouncementActivated,omitempty"`
		EnglishText                        *string `json:"EnglishText,omitempty"`
		PublicAnnouncementPlanList         *struct {
			PublicAnnouncementPlan []struct {
				ActiveDays                     *string `json:"ActiveDays,omitempty"`
				PublicAnnouncementOccasionList *struct {
					PublicAnnouncementOccasion []int `json:"PublicAnnouncementOccasion,omitempty"`
				} `json:"PublicAnnouncementOccasionList,omitempty"`
				ValidFrom *time.Time `json:"ValidFrom,omitempty"`
				ValidTo   *time.Time `json:"ValidTo,omitempty"`
			} `json:"PublicAnnouncementPlan,omitempty"`
		} `json:"PublicAnnouncementPlanList,omitempty"`
		PublicAnnouncementZoneList *struct {
			PublicAnnouncementZone []string `json:"PublicAnnouncementZone,omitempty"`
		} `json:"PublicAnnouncementZoneList,omitempty"`
	} `json:"PublicAnnouncementAttributes,omitempty"`
	SplitActivationTime *bool          `json:"SplitActivationTime,omitempty"`
	StartDateTime       *time.Time     `json:"StartDateTime,omitempty"`
	Status              *MessageStatus `json:"Status,omitempty"`
	VersionNumber       *int           `json:"VersionNumber,omitempty"`
}

type TravelTimeRoute1Dot0 ¶ added in v0.3.0

type TravelTimeRoute1Dot0 struct {
	AverageFunctionalRoadClass *int       `json:"AverageFunctionalRoadClass,omitempty"`
	Country                    *Country   `json:"CountryCode,omitempty"`
	County                     []County   `json:"CountyNo,omitempty"`
	Deleted                    *bool      `json:"Deleted,omitempty"`
	ExpectedFreeFlowTravelTime *int       `json:"ExpectedFreeFlowTravelTime,omitempty"`
	FreeFlowTravelTime         *int       `json:"FreeFlowTravelTime,omitempty"`
	Geometry                   *Geometry  `json:"Geometry,omitempty"`
	ID                         *string    `json:"Id,omitempty"`
	Length                     *int       `json:"Length,omitempty"`
	MeasureTime                *time.Time `json:"MeasureTime,omitempty"`
	ModifiedTime               *time.Time `json:"ModifiedTime,omitempty"`
	Name                       *string    `json:"Name,omitempty"`
	Speed                      *float64   `json:"Speed,omitempty"`
	Status                     *Status    `json:"Status,omitempty"`
	TravelTime                 *int       `json:"TravelTime,omitempty"`
}

type TravelTimeRoute1Dot3 ¶ added in v0.3.0

type TravelTimeRoute1Dot3 struct {
	AverageFunctionalRoadClass *int             `json:"AverageFunctionalRoadClass,omitempty"`
	Country                    *Country         `json:"CountryCode,omitempty"`
	County                     []County         `json:"CountyNo,omitempty"`
	Deleted                    *bool            `json:"Deleted,omitempty"`
	ExpectedFreeFlowTravelTime *int             `json:"ExpectedFreeFlowTravelTime,omitempty"`
	FreeFlowTravelTime         *int             `json:"FreeFlowTravelTime,omitempty"`
	Geometry                   *GeometryWithMod `json:"Geometry,omitempty"`
	ID                         *string          `json:"Id,omitempty"`
	Length                     *int             `json:"Length,omitempty"`
	MeasureTime                *time.Time       `json:"MeasureTime,omitempty"`
	ModifiedTime               *time.Time       `json:"ModifiedTime,omitempty"`
	Name                       *string          `json:"Name,omitempty"`
	RouteOwner                 *int             `json:"RouteOwner,omitempty"`
	Speed                      *float64         `json:"Speed,omitempty"`
	Status                     *Status          `json:"Status,omitempty"`
	TravelTime                 *int             `json:"TravelTime,omitempty"`
}

type TravelTimeRoute1Dot4 ¶ added in v0.3.0

type TravelTimeRoute1Dot4 struct {
	AverageFunctionalRoadClass *int             `json:"AverageFunctionalRoadClass,omitempty"`
	Country                    *Country         `json:"CountryCode,omitempty"`
	County                     []County         `json:"CountyNo,omitempty"`
	Deleted                    *bool            `json:"Deleted,omitempty"`
	ExpectedFreeFlowTravelTime *int             `json:"ExpectedFreeFlowTravelTime,omitempty"`
	FreeFlowTravelTime         *int             `json:"FreeFlowTravelTime,omitempty"`
	Geometry                   *GeometryWithMod `json:"Geometry,omitempty"`
	ID                         *string          `json:"Id,omitempty"`
	Length                     *int             `json:"Length,omitempty"`
	MeasureTime                *time.Time       `json:"MeasureTime,omitempty"`
	ModifiedTime               *time.Time       `json:"ModifiedTime,omitempty"`
	Name                       *string          `json:"Name,omitempty"`
	RouteOwner                 *int             `json:"RouteOwner,omitempty"`
	Speed                      *float64         `json:"Speed,omitempty"`
	TrafficStatus              *TrafficStatus   `json:"TrafficStatus,omitempty"`
	TravelTime                 *int             `json:"TravelTime,omitempty"`
}

type TravelTimeRoute1Dot5 ¶ added in v0.3.0

type TravelTimeRoute1Dot5 struct {
	AverageFunctionalRoadClass *int             `json:"AverageFunctionalRoadClass,omitempty"`
	Country                    *Country         `json:"CountryCode,omitempty"`
	County                     []County         `json:"CountyNo,omitempty"`
	Deleted                    *bool            `json:"Deleted,omitempty"`
	ExpectedFreeFlowTravelTime *float64         `json:"ExpectedFreeFlowTravelTime,omitempty"`
	FreeFlowTravelTime         *float64         `json:"FreeFlowTravelTime,omitempty"`
	Geometry                   *GeometryWithMod `json:"Geometry,omitempty"`
	ID                         *string          `json:"Id,omitempty"`
	Length                     *float64         `json:"Length,omitempty"`
	MeasureTime                *time.Time       `json:"MeasureTime,omitempty"`
	ModifiedTime               *time.Time       `json:"ModifiedTime,omitempty"`
	Name                       *string          `json:"Name,omitempty"`
	RouteOwner                 *int             `json:"RouteOwner,omitempty"`
	Speed                      *float64         `json:"Speed,omitempty"`
	TrafficStatus              *TrafficStatus   `json:"TrafficStatus,omitempty"`
	TravelTime                 *float64         `json:"TravelTime,omitempty"`
}

type Vehicle ¶ added in v0.3.0

type Vehicle string
const (
	VehicleAgricultural                       Vehicle = "agriculturalVehicle"
	VehicleAny                                Vehicle = "anyVehicle"
	VehicleArticulatedVehicle                 Vehicle = "articulatedVehicle"
	VehicleBicycle                            Vehicle = "bicycle"
	VehicleBus                                Vehicle = "bus"
	VehicleCar                                Vehicle = "car"
	VehicleACaravan                           Vehicle = "caravan"
	VehicleCarOrLightVehicle                  Vehicle = "carOrLightVehicle"
	VehicleCarWithCaravan                     Vehicle = "carWithCaravan"
	VehicleCarWithTrailer                     Vehicle = "carWithTrailer"
	VehicleConstructionOrMaintenanceVehicle   Vehicle = "constructionOrMaintenanceVehicle"
	VehicleFourWheelDrive                     Vehicle = "fourWheelDrive"
	VehicleHighSidedVehicle                   Vehicle = "highSidedVehicle"
	VehicleLorry                              Vehicle = "lorry"
	VehicleMoped                              Vehicle = "moped"
	VehicleMotorcycle                         Vehicle = "motorcycle"
	VehicleMotorcycleWithSideCar              Vehicle = "motorcycleWithSideCar"
	VehicleScooter                            Vehicle = "motorscooter"
	VehicleTanker                             Vehicle = "tanker"
	VehicleThreeWheeledVehicle                Vehicle = "threeWheeledVehicle"
	VehicleTrailer                            Vehicle = "trailer"
	VehicleTram                               Vehicle = "tram"
	VehicleTwoWheeledVehicle                  Vehicle = "twoWheeledVehicle"
	VehicleVan                                Vehicle = "van"
	VehicleWithCatalyticConverter             Vehicle = "vehicleWithCatalyticConverter"
	VehicleWithoutCatalyticConverter          Vehicle = "vehicleWithoutCatalyticConverter"
	VehicleWithCaravan                        Vehicle = "vehicleWithCaravan"
	VehicleWithTrailer                        Vehicle = "vehicleWithTrailer"
	VehicleWithEvenNumberedRegistrationPlates Vehicle = "withEvenNumberedRegistrationPlates"
	VehicleWithOddNumberedRegistrationPlates  Vehicle = "withOddNumberedRegistrationPlates"
	VehicleOther                              Vehicle = "other"
)

type Warning ¶ added in v0.3.0

type Warning string
const (
	WarningSlippingRisk Warning = "Risk för halka"
	WarningSlipping     Warning = "Halka"
	WarningSnowSmoke    Warning = "Snörök"
	WarningSnowdrift    Warning = "Snödrev"
	WarningHarshWind    Warning = "HĂĄrd vind"
	WarningSnow         Warning = "Snöfall"
	WarningOther        Warning = "Annat"
)

type WeatherMeasurepoint1Dot0 ¶ added in v0.4.0

type WeatherMeasurepoint1Dot0 struct {
	Deleted      *bool      `json:"Deleted,omitempty"`
	Geometry     *Geometry  `json:"Geometry,omitempty"`
	ID           *string    `json:"Id,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	Name         *string    `json:"Name,omitempty"`
	Observation  *struct {
		Aggregated10Minutes *struct {
			Precipitation *struct {
				Rain    *bool `json:"Rain,omitempty"`
				RainSum *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"RainSum"`
				Snow    *bool `json:"Snow,omitempty"`
				SnowSum *struct {
					Solid *struct {
						Origin      *Origin `json:"Origin,omitempty"`
						SensorNames *string `json:"SensorNames,omitempty"`
						Value       *int    `json:"Value,omitempty"`
					} `json:"Solid,omitempty"`
				} `json:"SnowSum,omitempty"`
				TotalWaterEquivalent *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"TotalWaterEquivalent,omitempty"`
			} `json:"Precipitation,omitempty"`
			Wind *struct {
				Height       *int `json:"Height,omitempty"`
				SpeedAverage *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedAverage,omitempty"`
				SpeedMax *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedMax,omitempty"`
			} `json:"Wind,omitempty"`
		} `json:"Aggregated10minutes,omitempty"`
		Aggregated30Minutes *struct {
			Precipitation *struct {
				Rain    *bool `json:"Rain,omitempty"`
				RainSum *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"RainSum"`
				Snow    *bool `json:"Snow,omitempty"`
				SnowSum *struct {
					Solid *struct {
						Origin      *Origin `json:"Origin,omitempty"`
						SensorNames *string `json:"SensorNames,omitempty"`
						Value       *int    `json:"Value,omitempty"`
					} `json:"Solid,omitempty"`
				} `json:"SnowSum,omitempty"`
				TotalWaterEquivalent *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"TotalWaterEquivalent,omitempty"`
			} `json:"Precipitation,omitempty"`
			Wind *struct {
				Height       *int `json:"Height,omitempty"`
				SpeedAverage *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedAverage,omitempty"`
				SpeedMax *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedMax,omitempty"`
			} `json:"Wind,omitempty"`
		} `json:"Aggregated30minutes,omitempty"`
		Aggregated5Minutes *struct {
			Precipitation *struct {
				Rain    *bool `json:"Rain,omitempty"`
				RainSum *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"RainSum"`
				Snow    *bool `json:"Snow,omitempty"`
				SnowSum *struct {
					Solid *struct {
						Origin      *Origin `json:"Origin,omitempty"`
						SensorNames *string `json:"SensorNames,omitempty"`
						Value       *int    `json:"Value,omitempty"`
					} `json:"Solid,omitempty"`
				} `json:"SnowSum,omitempty"`
				TotalWaterEquivalent *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"TotalWaterEquivalent,omitempty"`
			} `json:"Precipitation,omitempty"`
			Wind *struct {
				Height       *int `json:"Height,omitempty"`
				SpeedAverage *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedAverage,omitempty"`
				SpeedMax *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedMax,omitempty"`
			} `json:"Wind,omitempty"`
		} `json:"Aggregated5minutes,omitempty"`
		Air *struct {
			Dewpoint *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Dewpoint,omitempty"`
			RelativeHumidity *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"RelativeHumidity,omitempty"`
			Temperature *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Temperature,omitempty"`
			VisibleDistance *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"VisibleDistance,omitempty"`
		} `json:"Air,omitempty"`
		ID         *string    `json:"Id,omitempty"`
		Sample     *time.Time `json:"Sample,omitempty"`
		Subsurface *struct {
			Ground []struct {
				Depth *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"Depth,omitempty"`
				Temperature *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"Temperature,omitempty"`
			} `json:"Ground,omitempty"`
		} `json:"Subsurface,omitempty"`
		Surface *struct {
			Grip *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Grip,omitempty"`
			Ice      *bool `json:"Ice,omitempty"`
			IceDepth *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"IceDepth,omitempty"`
			Snow      *bool `json:"Snow,omitempty"`
			SnowDepth *struct {
				Solid *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
				WaterEquivalent *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"WaterEquivalent,omitempty"`
			} `json:"SnowDepth,omitempty"`
			Temperature *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Temperature,omitempty"`
			Water      *bool `json:"Water,omitempty"`
			WaterDepth *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"WaterDepth,omitempty"`
		} `json:"Surface,omitempty"`
		Wind [2]struct {
			Direction *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Direction,omitempty"`
			Height *int `json:"Height,omitempty"`
			Speed  *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Speed,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Observation,omitempty"`
}

type WeatherMeasurepoint2Dot0 ¶ added in v0.4.0

type WeatherMeasurepoint2Dot0 struct {
	Deleted      *bool      `json:"Deleted,omitempty"`
	Geometry     *Geometry  `json:"Geometry,omitempty"`
	ID           *string    `json:"Id,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	Name         *string    `json:"Name,omitempty"`
	Observation  *struct {
		Aggregated10Minutes *struct {
			Precipitation *struct {
				Rain    *bool `json:"Rain,omitempty"`
				RainSum *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"RainSum"`
				Snow    *bool `json:"Snow,omitempty"`
				SnowSum *struct {
					Solid *struct {
						Origin      *Origin `json:"Origin,omitempty"`
						SensorNames *string `json:"SensorNames,omitempty"`
						Value       *int    `json:"Value,omitempty"`
					} `json:"Solid,omitempty"`
				} `json:"SnowSum,omitempty"`
				TotalWaterEquivalent *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"TotalWaterEquivalent,omitempty"`
			} `json:"Precipitation,omitempty"`
			Wind *struct {
				Height       *int `json:"Height,omitempty"`
				SpeedAverage *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedAverage,omitempty"`
				SpeedMax *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedMax,omitempty"`
			} `json:"Wind,omitempty"`
		} `json:"Aggregated10minutes,omitempty"`
		Aggregated30Minutes *struct {
			Precipitation *struct {
				Rain    *bool `json:"Rain,omitempty"`
				RainSum *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"RainSum"`
				Snow    *bool `json:"Snow,omitempty"`
				SnowSum *struct {
					Solid *struct {
						Origin      *Origin `json:"Origin,omitempty"`
						SensorNames *string `json:"SensorNames,omitempty"`
						Value       *int    `json:"Value,omitempty"`
					} `json:"Solid,omitempty"`
				} `json:"SnowSum,omitempty"`
				TotalWaterEquivalent *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"TotalWaterEquivalent,omitempty"`
			} `json:"Precipitation,omitempty"`
			Wind *struct {
				Height       *int `json:"Height,omitempty"`
				SpeedAverage *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedAverage,omitempty"`
				SpeedMax *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedMax,omitempty"`
			} `json:"Wind,omitempty"`
		} `json:"Aggregated30minutes,omitempty"`
		Aggregated5Minutes *struct {
			Precipitation *struct {
				Rain    *bool `json:"Rain,omitempty"`
				RainSum *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"RainSum"`
				Snow    *bool `json:"Snow,omitempty"`
				SnowSum *struct {
					Solid *struct {
						Origin      *Origin `json:"Origin,omitempty"`
						SensorNames *string `json:"SensorNames,omitempty"`
						Value       *int    `json:"Value,omitempty"`
					} `json:"Solid,omitempty"`
				} `json:"SnowSum,omitempty"`
				TotalWaterEquivalent *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"TotalWaterEquivalent,omitempty"`
			} `json:"Precipitation,omitempty"`
			Wind *struct {
				Height       *int `json:"Height,omitempty"`
				SpeedAverage *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedAverage,omitempty"`
				SpeedMax *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"SpeedMax,omitempty"`
			} `json:"Wind,omitempty"`
		} `json:"Aggregated5minutes,omitempty"`
		Air *struct {
			Dewpoint *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Dewpoint,omitempty"`
			RelativeHumidity *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"RelativeHumidity,omitempty"`
			Temperature *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Temperature,omitempty"`
			VisibleDistance *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"VisibleDistance,omitempty"`
		} `json:"Air,omitempty"`
		ID         *string    `json:"Id,omitempty"`
		Sample     *time.Time `json:"Sample,omitempty"`
		Subsurface *struct {
			Ground []struct {
				Depth *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"Depth,omitempty"`
				Temperature *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"Temperature,omitempty"`
			} `json:"Ground,omitempty"`
		} `json:"Subsurface,omitempty"`
		Surface *struct {
			Grip *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Grip,omitempty"`
			Ice      *bool `json:"Ice,omitempty"`
			IceDepth *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"IceDepth,omitempty"`
			Snow      *bool `json:"Snow,omitempty"`
			SnowDepth *struct {
				Solid *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
				WaterEquivalent *struct {
					Origin      *Origin  `json:"Origin,omitempty"`
					SensorNames *string  `json:"SensorNames,omitempty"`
					Value       *float64 `json:"Value,omitempty"`
				} `json:"WaterEquivalent,omitempty"`
			} `json:"SnowDepth,omitempty"`
			Temperature *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Temperature,omitempty"`
			Water      *bool `json:"Water,omitempty"`
			WaterDepth *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"WaterDepth,omitempty"`
		} `json:"Surface,omitempty"`
		Weather *struct {
			Precipitation *PrecipitationTypeMeasure `json:"Precipitation,omitempty"`
		} `json:"Weather,omitempty"`
		Wind [2]struct {
			Direction *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Direction,omitempty"`
			Height *int `json:"Height,omitempty"`
			Speed  *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Speed,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Observation,omitempty"`
}

type WeatherObservation1Dot0 ¶ added in v0.4.0

type WeatherObservation1Dot0 struct {
	Aggregated10Minutes *struct {
		Precipitation *struct {
			Rain    *bool `json:"Rain,omitempty"`
			RainSum *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"RainSum"`
			Snow    *bool `json:"Snow,omitempty"`
			SnowSum *struct {
				Solid *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
			} `json:"SnowSum,omitempty"`
			TotalWaterEquivalent *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"TotalWaterEquivalent,omitempty"`
		} `json:"Precipitation,omitempty"`
		Wind *struct {
			Height       *int `json:"Height,omitempty"`
			SpeedAverage *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedAverage,omitempty"`
			SpeedMax *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Aggregated10minutes,omitempty"`
	Aggregated30Minutes *struct {
		Precipitation *struct {
			Rain    *bool `json:"Rain,omitempty"`
			RainSum *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"RainSum"`
			Snow    *bool `json:"Snow,omitempty"`
			SnowSum *struct {
				Solid *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
			} `json:"SnowSum,omitempty"`
			TotalWaterEquivalent *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"TotalWaterEquivalent,omitempty"`
		} `json:"Precipitation,omitempty"`
		Wind *struct {
			Height       *int `json:"Height,omitempty"`
			SpeedAverage *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedAverage,omitempty"`
			SpeedMax *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Aggregated30minutes,omitempty"`
	Aggregated5Minutes struct {
		Precipitation *struct {
			Rain    *bool `json:"Rain,omitempty"`
			RainSum *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"RainSum"`
			Snow    *bool `json:"Snow,omitempty"`
			SnowSum *struct {
				Solid *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
			} `json:"SnowSum,omitempty"`
			TotalWaterEquivalent *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"TotalWaterEquivalent,omitempty"`
		} `json:"Precipitation,omitempty"`
		Wind *struct {
			Height       *int `json:"Height,omitempty"`
			SpeedAverage *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedAverage,omitempty"`
			SpeedMax *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Aggregated5minutes,omitempty"`
	Air *struct {
		Dewpoint *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Dewpoint,omitempty"`
		RelativeHumidity *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"RelativeHumidity,omitempty"`
		Temperature *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Temperature,omitempty"`
		VisibleDistance *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"VisibleDistance,omitempty"`
	} `json:"Air,omitempty"`
	DeicingChemical *struct {
		Amount *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Amount,omitempty"`
	} `json:"DeicingChemical,omitempty"`
	Deleted      *bool      `json:"Deleted,omitempty"`
	ID           *string    `json:"Id,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	Measurepoint *struct {
		ID       *int      `json:"Id,omitempty"`
		Name     *string   `json:"Name,omitempty"`
		Geometry *Geometry `json:"Geometry,omitempty"`
	} `json:"Measurepoint,omitempty"`
	Sample     *time.Time `json:"Sample,omitempty"`
	Subsurface *struct {
		Ground []struct {
			Depth *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Depth,omitempty"`
			Temperature *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Temperature,omitempty"`
		} `json:"Ground,omitempty"`
	} `json:"Subsurface,omitempty"`
	Surface *struct {
		Grip *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Grip,omitempty"`
		Ice      *bool `json:"Ice,omitempty"`
		IceDepth *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"IceDepth,omitempty"`
		Snow      *bool `json:"Snow,omitempty"`
		SnowDepth *struct {
			Solid *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Solid,omitempty"`
			WaterEquivalent *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"WaterEquivalent,omitempty"`
		} `json:"SnowDepth,omitempty"`
		Temperature *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Temperature,omitempty"`
		Water      *bool `json:"Water,omitempty"`
		WaterDepth *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"WaterDepth,omitempty"`
	} `json:"Surface,omitempty"`
	Wind [2]struct {
		Direction *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Direction,omitempty"`
		Height *int `json:"Height,omitempty"`
		Speed  *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Speed,omitempty"`
	} `json:"Wind,omitempty"`
}

type WeatherObservation2Dot0 ¶ added in v0.4.0

type WeatherObservation2Dot0 struct {
	Aggregated10Minutes *struct {
		Precipitation *struct {
			Rain    *bool `json:"Rain,omitempty"`
			RainSum *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"RainSum"`
			Snow    *bool `json:"Snow,omitempty"`
			SnowSum *struct {
				Solid *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
			} `json:"SnowSum,omitempty"`
			TotalWaterEquivalent *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"TotalWaterEquivalent,omitempty"`
		} `json:"Precipitation,omitempty"`
		Wind *struct {
			Height       *int `json:"Height,omitempty"`
			SpeedAverage *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedAverage,omitempty"`
			SpeedMax *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Aggregated10minutes,omitempty"`
	Aggregated30Minutes *struct {
		Precipitation *struct {
			Rain    *bool `json:"Rain,omitempty"`
			RainSum *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"RainSum"`
			Snow    *bool `json:"Snow,omitempty"`
			SnowSum *struct {
				Solid *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
			} `json:"SnowSum,omitempty"`
			TotalWaterEquivalent *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"TotalWaterEquivalent,omitempty"`
		} `json:"Precipitation,omitempty"`
		Wind *struct {
			Height       *int `json:"Height,omitempty"`
			SpeedAverage *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedAverage,omitempty"`
			SpeedMax *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Aggregated30minutes,omitempty"`
	Aggregated5Minutes struct {
		Precipitation *struct {
			Rain    *bool `json:"Rain,omitempty"`
			RainSum *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"RainSum"`
			Snow    *bool `json:"Snow,omitempty"`
			SnowSum *struct {
				Solid *struct {
					Origin      *Origin `json:"Origin,omitempty"`
					SensorNames *string `json:"SensorNames,omitempty"`
					Value       *int    `json:"Value,omitempty"`
				} `json:"Solid,omitempty"`
			} `json:"SnowSum,omitempty"`
			TotalWaterEquivalent *struct {
				Origin      *Origin `json:"Origin,omitempty"`
				SensorNames *string `json:"SensorNames,omitempty"`
				Value       *int    `json:"Value,omitempty"`
			} `json:"TotalWaterEquivalent,omitempty"`
		} `json:"Precipitation,omitempty"`
		Wind *struct {
			Height       *int `json:"Height,omitempty"`
			SpeedAverage *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedAverage,omitempty"`
			SpeedMax *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"SpeedMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Aggregated5minutes,omitempty"`
	Air *struct {
		Dewpoint *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Dewpoint,omitempty"`
		RelativeHumidity *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"RelativeHumidity,omitempty"`
		Temperature *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Temperature,omitempty"`
		VisibleDistance *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"VisibleDistance,omitempty"`
	} `json:"Air,omitempty"`
	DeicingChemical *struct {
		Amount *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Amount,omitempty"`
	} `json:"DeicingChemical,omitempty"`
	Deleted      *bool      `json:"Deleted,omitempty"`
	ID           *string    `json:"Id,omitempty"`
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	Measurepoint *struct {
		ID       *int      `json:"Id,omitempty"`
		Name     *string   `json:"Name,omitempty"`
		Geometry *Geometry `json:"Geometry,omitempty"`
	} `json:"Measurepoint,omitempty"`
	Sample     *time.Time `json:"Sample,omitempty"`
	Subsurface *struct {
		Ground []struct {
			Depth *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Depth,omitempty"`
			Temperature *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Temperature,omitempty"`
		} `json:"Ground,omitempty"`
	} `json:"Subsurface,omitempty"`
	Surface *struct {
		Grip *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Grip,omitempty"`
		Ice      *bool `json:"Ice,omitempty"`
		IceDepth *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"IceDepth,omitempty"`
		Snow      *bool `json:"Snow,omitempty"`
		SnowDepth *struct {
			Solid *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"Solid,omitempty"`
			WaterEquivalent *struct {
				Origin      *Origin  `json:"Origin,omitempty"`
				SensorNames *string  `json:"SensorNames,omitempty"`
				Value       *float64 `json:"Value,omitempty"`
			} `json:"WaterEquivalent,omitempty"`
		} `json:"SnowDepth,omitempty"`
		Temperature *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Temperature,omitempty"`
		Water      *bool `json:"Water,omitempty"`
		WaterDepth *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"WaterDepth,omitempty"`
	} `json:"Surface,omitempty"`
	Weather *struct {
		Precipitation *PrecipitationTypeMeasure `json:"Precipitation,omitempty"`
	} `json:"Weather,omitempty"`
	Wind [2]struct {
		Direction *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Direction,omitempty"`
		Height *int `json:"Height,omitempty"`
		Speed  *struct {
			Origin      *Origin  `json:"Origin,omitempty"`
			SensorNames *string  `json:"SensorNames,omitempty"`
			Value       *float64 `json:"Value,omitempty"`
		} `json:"Speed,omitempty"`
	} `json:"Wind,omitempty"`
}

type WeatherStation1Dot0 ¶ added in v0.2.0

type WeatherStation1Dot0 struct {
	// Active indicates this station is returning data
	Active *bool `json:"Active,omitempty"`
	// County is the Swedish county in which this station is located
	County []County `json:"CountyNo,omitempty"`
	// Deleted indicates if this is a deleted object. This should only
	// ever be true if you created a Query with IncludeDeletedItems
	Deleted *bool `json:"Deleted,omitempty"`
	// Geometry contains coordinates for where this station is located
	Geometry *Geometry `json:"Geometry,omitempty"`
	// IconID is an identifier that can be used with a query for the Icon
	// object type to retrieve the base64 encoded PNG and the URL at which
	// the icon can also be retrieved
	IconID *string `json:"IconId,omitempty"`
	// ID is the unique ID identifying this station
	ID *string `json:"Id,omitempty"`
	// Measurement represents measurement data from environmental sensors
	Measurement *struct {
		// Air contains the typical things like relative humidity and temperature
		// as measured in the air
		Air *struct {
			// RelativeHumidity is the relative humidity in percent
			RelativeHumidity *float64 `json:"RelativeHumidity,omitempty"`
			// Temperature is measured in degrees Celsius
			Temperature       *float64 `json:"Temp,omitempty"`
			TemperatureIconID *string  `json:"TempIconId,omitempty"`
		} `json:"Air,omitempty"`
		// MeasurTime indicates when these values where recorded
		MeasureTime *time.Time `json:"MeasureTime,omitempty"`
		// Precipitation contains the type and amount of precipitation
		Precipitation *struct {
			// Amount is the mount of rain in mm per hour. It's worth noting
			// that in practice it turns out the absence of a value indicates
			// "no rain", i.e precipitation of 0, not "this station doesn't
			// report precipitation", unless Measurement was Excluded by the
			// Query
			Amount *float64 `json:"Amount,omitempty"`
			// AmountName is a predefined string describing the type and amount
			// of precipitation in Swedish
			AmountName *PrecipitationAmount `json:"AmountName,omitempty"`
			// Type is a predefined string describing the type of precipitation
			// in Swedish
			Type       *PrecipitationType `json:"Type,omitempty"`
			TypeIconID *string            `json:"TypeIconId,omitempty"`
		} `json:"Precipitation,omitempty"`
		// Road contains the temperature as measured at the road deck level.
		// This can be much higher or lower than the Air values
		Road *struct {
			// Temperature is measured in degrees Celsius
			Temperature       *float64 `json:"Temp,omitempty"`
			TemperatureIconID *string  `json:"TempIconId,omitempty"`
		} `json:"Road,omitempty"`
		// Wind contains wind direction and strength
		Wind *struct {
			// Direction is represented in degrees
			Direction       *float64 `json:"Direction,omitempty"`
			DirectionIconID *string  `json:"DirectionIconId,omitempty"`
			// DirectionText is a predefined string representing the wind
			// direction in Swedish
			DirectionText *WindDirection `json:"DirectionText,omitempty"`
			// Force is the 10 minute average in m/sec
			Force *float64 `json:"Force,omitempty"`
			// ForceMax is the 30 minute max in m/sec
			ForceMax *float64 `json:"ForceMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"Measurement,omitempty"`
	// MeasurementHistory contains multiple instances of Measurement
	// over time. See the comments on Measurement for how to interpret
	// the data
	MeasurementHistory []struct {
		Air *struct {
			RelativeHumidity  *float64 `json:"RelativeHumidity,omitempty"`
			Temperature       *float64 `json:"Temp,omitempty"`
			TemperatureIconID *string  `json:"TempIconId,omitempty"`
		} `json:"Air,omitempty"`
		MeasureTime   *time.Time `json:"MeasureTime,omitempty"`
		Precipitation *struct {
			Amount     *float64             `json:"Amount,omitempty"`
			AmountName *PrecipitationAmount `json:"AmountName,omitempty"`
			Type       *PrecipitationType   `json:"Type,omitempty"`
			TypeIconID *string              `json:"TypeIconId,omitempty"`
		} `json:"Precipitation,omitempty"`
		Road *struct {
			Temperature       *float64 `json:"Temp,omitempty"`
			TemperatureIconID *string  `json:"TempIconId,omitempty"`
		} `json:"Road,omitempty"`
		Wind *struct {
			Direction       *float64       `json:"Direction,omitempty"`
			DirectionIconID *string        `json:"DirectionIconId,omitempty"`
			DirectionText   *WindDirection `json:"DirectionText,omitempty"`
			Force           *float64       `json:"Force,omitempty"`
			ForceMax        *float64       `json:"ForceMax,omitempty"`
		} `json:"Wind,omitempty"`
	} `json:"MeasurementHistory,omitempty"`
	// ModifiedTime represents when this object was last modified
	ModifiedTime *time.Time `json:"ModifiedTime,omitempty"`
	// Name is the name of the station
	Name *string `json:"Name,omitempty"`
	// RoadNumber is the Swedish road number this station is located at
	RoadNumber *int `json:"RoadNumberNumeric,omitempty"`
}

WeatherStation1Dot0 is the WeatherStation v1.0 model. It returns all kinds of environmental data

type WindDirection ¶ added in v0.2.0

type WindDirection string
const (
	WindDirectionN   WindDirection = "Norr"
	WindDirectionNE  WindDirection = "Nordöst"
	WindDirectionNNE WindDirection = "Nordnordöst"
	WindDirectionNNW WindDirection = "Nordnordväst"
	WindDirectionNW  WindDirection = "Nordväst"

	WindDirectionE   WindDirection = "Ă–st"
	WindDirectionESE WindDirection = "Östsydöst"

	WindDirectionS   WindDirection = "Söder"
	WindDirectionSE  WindDirection = "Sydöst"
	WindDirectionSSW WindDirection = "Sydsydväst"
	WindDirectionSW  WindDirection = "Sydväst"

	WindDirectionW WindDirection = "Väst"
)

Directories ¶

Path Synopsis
examples

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL