apiserver

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2020 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Start

func Start(conf *config.Settings, addr string) error

Start starts http server on the specified addr.

Types

type Result

type Result struct {
	VIN     VIN     `json:"vin"`
	Vehicle Vehicle `json:"vehicle"`
}

Result is a union of information about vin-code and decoded vehicle.

func NewResult

func NewResult(store store.Store, vin *govin.VIN) *Result

type VIN

type VIN struct {
	WMI string `json:"wmi"` // World manufacturer identifier.
	VDS string `json:"vds"` // Vehicle descriptor section.
	VIS string `json:"vis"` // Vehicle identifier section.
}

VIN represents detailed information about the VIN code.

type Vehicle

type Vehicle struct {
	Manufacturer string       `json:"manufacturer"`
	Country      string       `json:"country"`
	Year         *uint        `json:"year,omitempty"`
	Region       govin.Region `json:"region"`
	Check        bool         `json:"check"`
}

Vehicle represent information about the decoded vehicle.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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