Documentation
¶
Index ¶
Constants ¶
View Source
const ( STOPPED = iota + 1 RUNNING PAUSED PREPARING STARTED FINISHED HOMEWARD OUTWARD RESTING )
View Source
const DIRECTED_GRAPH = false
directed graph uses oneway, causes problems
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActionType ¶
type ActionType int
type FeatureCollection ¶
type FeatureCollection struct {
Type string `json:"type" bson:"type"`
Feature *[]Feature `json:"features" bson:"features"`
Name string `json:"name" bson:"name"`
}
func ReadAllPOIs ¶
func ReadAllPOIs() (*FeatureCollection, error)
type Fleet ¶
func GetINSTANCE ¶ added in v0.0.2
func GetINSTANCE() *Fleet
type GeoJSON ¶ added in v0.0.2
type GeoJSON struct {
Type string `json:"type" bson:"type"`
Coordinates []float64 `json:"coordinates" bson:"coordinates"`
}
{"type":"Point","coordinates":[12.4045328,51.7979734]}
type Node ¶
type Node struct {
ID int64 `json:"id" bson:"_id" db:"id"`
Lon float64 `json:"lon" bson:"lon" db:"lon"`
Lat float64 `json:"lat" bson:"lat" db:"lat"`
}
func FindNearestNodeForPOI ¶
type PostionEvent ¶ added in v0.0.2
type RouteEvent ¶
type Truck ¶
type Truck struct {
ID int64 `json:"id" bson:"_id"`
Name string `json:"name" bson:"name"`
Position *Position `json:"pos" bson:"pos"`
Route *Route `json:"route" bson:"route"`
Base int64 `json:"base" bson:"base"`
ActionType ActionType `json:"action" bson:"action"`
}
func (*Truck) SetActionType ¶
func (truck *Truck) SetActionType(ActionType ActionType)
func (*Truck) StartOrder ¶
type TruckActionEvent ¶
type TruckActionEvent struct {
ID int64 `json:"id" bson:"_id"`
Name string `json:"name" bson:"name"`
ActionType ActionType `json:"action" bson:"action"`
}
Click to show internal directories.
Click to hide internal directories.