vehicletracker

package
v0.0.0-...-73876c2 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2024 License: GPL-3.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateIdentificationCache

func CreateIdentificationCache()

func RegisterCLI

func RegisterCLI() *cli.Command

func StartCleaner

func StartCleaner()

func StartConsumers

func StartConsumers()

func StartStatsServer

func StartStatsServer()

Types

type BatchConsumer

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

func NewBatchConsumer

func NewBatchConsumer(id int) *BatchConsumer

func (*BatchConsumer) Consume

func (consumer *BatchConsumer) Consume(batch rmq.Deliveries)

type CacheJourney

type CacheJourney struct {
	Path []*ctdf.JourneyPathItem `groups:"detailed"`
}

func (CacheJourney) MarshalBinary

func (j CacheJourney) MarshalBinary() ([]byte, error)

type HealthHandler

type HealthHandler struct {
}

func NewHealthHandler

func NewHealthHandler() *HealthHandler

func (*HealthHandler) ServeHTTP

func (handler *HealthHandler) ServeHTTP(writer http.ResponseWriter, _ *http.Request)

type RealtimeIdentifyFailureElasticEvent

type RealtimeIdentifyFailureElasticEvent struct {
	Timestamp time.Time

	Success    bool
	FailReason string

	Operator string
	Service  string
	Trip     string

	SourceType string
}

type StatsServerHandler

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

func NewStatsHandler

func NewStatsHandler(connection rmq.Connection) *StatsServerHandler

func (*StatsServerHandler) ServeHTTP

func (handler *StatsServerHandler) ServeHTTP(writer http.ResponseWriter, request *http.Request)

type VehicleLocationEvent

type VehicleLocationEvent struct {
	LocalID string

	IdentifyingInformation map[string]string
	SourceType             string

	Location  ctdf.Location
	Bearing   float64
	Timeframe string

	StopUpdates []VehicleLocationEventStopUpdate

	Occupancy ctdf.RealtimeJourneyOccupancy

	VehicleIdentifier string

	DataSource *ctdf.DataSource
	RecordedAt time.Time
}

type VehicleLocationEventStopUpdate

type VehicleLocationEventStopUpdate struct {
	StopID string

	ArrivalTime   time.Time
	DepartureTime time.Time

	ArrivalOffset   int
	DepartureOffset int
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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