openapi

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2019 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Index

func Index(w http.ResponseWriter, r *http.Request)

func Logger

func Logger(inner http.Handler, name string) http.Handler

func NewRouter

func NewRouter() *mux.Router

func SysPoweroff

func SysPoweroff(w http.ResponseWriter, r *http.Request)

SysPoweroff - System shutdown or reboot

func SysTimedateGet

func SysTimedateGet(w http.ResponseWriter, r *http.Request)

SysTimedateGet - The time date of this machine

func SysTimedateSync

func SysTimedateSync(w http.ResponseWriter, r *http.Request)

SysTimedateSync - Synchronize clock to NTP server on this machine

func WifiReconnect

func WifiReconnect(w http.ResponseWriter, r *http.Request)

WifiReconnect - Re-connect to wifi

func WifiStatus

func WifiStatus(w http.ResponseWriter, r *http.Request)

WifiStatus - Status of wifi

Types

type Date

type Date struct {
	Date string `json:"date"`
}

type Error

type Error struct {
	Code int32 `json:"code"`

	Message string `json:"message"`
}

type Power

type Power string
const (
	SHUTDOWN Power = "shutdown"
	REBOOT   Power = "reboot"
)

List of Power

type Route

type Route struct {
	Name        string
	Method      string
	Pattern     string
	HandlerFunc http.HandlerFunc
}

type Routes

type Routes []Route

type Status

type Status struct {
	Device string `json:"device"`

	Connected bool `json:"connected"`

	Signal int32 `json:"signal"`
}

Jump to

Keyboard shortcuts

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