Documentation ¶
Index ¶
- type AgencyListResponse
- type AgencyListResponse_Agency
- type Client
- func (c *Client) AgencyList() (*AgencyListResponse, error)
- func (c *Client) Messages(agency string, routeTags ...string) (*MessagesResponse, error)
- func (c *Client) PredictionsForStopId(agency, stopId string) (*PredictionsResponse, error)
- func (c *Client) PredictionsForStopTag(agency, routeTag, stopTag string) (*PredictionsResponse, error)
- func (c *Client) RouteConfig(agency, routeTag string) (*RouteConfigResponse, error)
- func (c *Client) RouteList(agency string) (*RouteListResponse, error)
- func (c *Client) Schedule(agency, routeTag string) (*ScheduleResponse, error)
- func (c *Client) VehicleLocations(agency, routeTag string, lastUpdatedMs uint64) (*VehicleLocationsResponse, error)
- type MessagesResponse
- type PredictionsResponse
- type PredictionsResponse_Direction
- type PredictionsResponse_Message
- type PredictionsResponse_Prediction
- type PredictionsResponse_Predictions
- type Response
- type Response_Error
- type RouteConfigResponse
- type RouteConfigResponse_Direction
- type RouteConfigResponse_Path
- type RouteConfigResponse_Point
- type RouteConfigResponse_Route
- type RouteConfigResponse_Stop
- type RouteConfigResponse_StopTag
- type RouteListResponse
- type RouteListResponse_Route
- type ScheduleResponse
- type VehicleLocationsResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AgencyListResponse ¶
type AgencyListResponse struct { Response Agencies []AgencyListResponse_Agency `xml:"agency"` }
type Client ¶
type Client struct { URL string // contains filtered or unexported fields }
func (*Client) AgencyList ¶
func (c *Client) AgencyList() (*AgencyListResponse, error)
func (*Client) Messages ¶
func (c *Client) Messages(agency string, routeTags ...string) (*MessagesResponse, error)
func (*Client) PredictionsForStopId ¶
func (c *Client) PredictionsForStopId(agency, stopId string) (*PredictionsResponse, error)
func (*Client) PredictionsForStopTag ¶
func (c *Client) PredictionsForStopTag(agency, routeTag, stopTag string) (*PredictionsResponse, error)
func (*Client) RouteConfig ¶
func (c *Client) RouteConfig(agency, routeTag string) (*RouteConfigResponse, error)
func (*Client) Schedule ¶
func (c *Client) Schedule(agency, routeTag string) (*ScheduleResponse, error)
func (*Client) VehicleLocations ¶
func (c *Client) VehicleLocations(agency, routeTag string, lastUpdatedMs uint64) (*VehicleLocationsResponse, error)
type MessagesResponse ¶
type MessagesResponse struct { // TODO: not implemented Response }
type PredictionsResponse ¶
type PredictionsResponse struct { Response Prediction PredictionsResponse_Predictions `xml:"predictions"` }
type PredictionsResponse_Direction ¶
type PredictionsResponse_Direction struct { Title string `xml:"title,attr"` Predictions []PredictionsResponse_Prediction `xml:"prediction"` }
type PredictionsResponse_Prediction ¶
type PredictionsResponse_Prediction struct { EpochTime uint64 `xml:"epochTime,attr"` Seconds uint32 `xml:"seconds,attr"` Minutes uint32 `xml:"minutes,attr"` IsDeparture bool `xml:"isDeparture,attr"` DirTag string `xml:"dirTag,attr"` Vehicle string `xml:"vehicle,attr"` VehiclesInConsist uint32 `xml:"vehiclesInConsist,attr"` Block string `xml:"block,attr"` TripTag string `xml:"tripTag,attr"` }
type PredictionsResponse_Predictions ¶
type PredictionsResponse_Predictions struct { AgencyTitle string `xml:"agencyTitle,attr"` RouteTitle string `xml:"routeTitle,attr"` RouteTag string `xml:"routeTag,attr"` StopTitle string `xml:"stopTitle,attr"` StopTag string `xml:"stopTag,attr"` Directions []PredictionsResponse_Direction `xml:"direction"` Message PredictionsResponse_Message `xml:"message"` }
type Response ¶
type Response struct { XMLName xml.Name `xml:"body"` Error *Response_Error `xml:"Error"` }
type Response_Error ¶
type RouteConfigResponse ¶
type RouteConfigResponse struct { Response Route RouteConfigResponse_Route `xml:"route"` }
type RouteConfigResponse_Direction ¶
type RouteConfigResponse_Direction struct { Tag string `xml:"tag,attr"` Title string `xml:"title,attr"` Name string `xml:"name,attr"` UseForUI bool `xml:"useForUI,attr"` Stops []RouteConfigResponse_StopTag `xml:"stop"` }
type RouteConfigResponse_Path ¶
type RouteConfigResponse_Path struct {
Points []RouteConfigResponse_Point `xml:"point"`
}
type RouteConfigResponse_Route ¶
type RouteConfigResponse_Route struct { Tag string `xml:"tag,attr"` Title string `xml:"title,attr"` Color string `xml:"color,attr"` OppositeColor string `xml:"oppositeColor,attr"` LatMin float32 `xml:"latMin,attr"` LatMax float32 `xml:"latMax,attr"` LonMin float32 `xml:"lonMin,attr"` LonMax float32 `xml:"lonMax,attr"` Stops []RouteConfigResponse_Stop `xml:"stop"` Directions []RouteConfigResponse_Direction `xml:"direction"` Paths []RouteConfigResponse_Path `xml:"path"` }
type RouteConfigResponse_StopTag ¶
type RouteConfigResponse_StopTag struct {
Tag string `xml:"tag,attr"`
}
type RouteListResponse ¶
type RouteListResponse struct { Response Routes []RouteListResponse_Route `xml:"route"` }
type RouteListResponse_Route ¶
type ScheduleResponse ¶
type ScheduleResponse struct { // TODO: not implemented Response }
type VehicleLocationsResponse ¶
type VehicleLocationsResponse struct { // TODO: not implemented Response }
Click to show internal directories.
Click to hide internal directories.