webapi

package
v0.0.0-...-a1350e7 Latest Latest
Warning

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

Go to latest
Published: May 11, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type JsonValidator

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

func (*JsonValidator) Validate

func (cv *JsonValidator) Validate(i interface{}) error

type StatusPostBody

type StatusPostBody struct {
	Status *bool `json:"status" validate:"required"`
}

type TimerTimePostBody

type TimerTimePostBody struct {
	Hour   *int `json:"hour"   validate:"required"`
	Minute *int `json:"minute" validate:"required"`
}

type WebAPI

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

func New

func New(mc302vc *mc302vc.MC302VC, username, password string) *WebAPI

func (*WebAPI) BasicAuthMiddleware

func (a *WebAPI) BasicAuthMiddleware() echo.MiddlewareFunc

func (*WebAPI) ErrorHandler

func (a *WebAPI) ErrorHandler(err error, c echo.Context)

func (*WebAPI) GetStatus

func (a *WebAPI) GetStatus(c echo.Context) error

func (*WebAPI) NewJsonValidator

func (a *WebAPI) NewJsonValidator() *JsonValidator

func (*WebAPI) SetBathAdditionalHeating

func (a *WebAPI) SetBathAdditionalHeating(c echo.Context) error

func (*WebAPI) SetBathAuto

func (a *WebAPI) SetBathAuto(c echo.Context) error

func (*WebAPI) SetBathAutoTimer

func (a *WebAPI) SetBathAutoTimer(c echo.Context) error

func (*WebAPI) SetBathAutoTimerTime

func (a *WebAPI) SetBathAutoTimerTime(c echo.Context) error

Jump to

Keyboard shortcuts

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