hueemulator

package
v2.4.0 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetPrimaryIp

func GetPrimaryIp() string

func Handle

func Handle(id int, deviceName string, h Handler)

func ListenAndServe

func ListenAndServe(addr string) error

func SetDebug

func SetDebug(d bool)

func SetLogger

func SetLogger(w io.Writer)

Types

type Handler

type Handler func(Request) error

Handler:

	state is the state of the "light" after the handler function
 if error is set to true echo will reply with "sorry the device is not responding"

type Request

type Request struct {
	UserId string
	// RequestedOnState bool
	Request    *request
	RemoteAddr string
}

Jump to

Keyboard shortcuts

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