commands

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2023 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ControllableName = "io:ExteriorVenetianBlindIOComponent"
)

Variables

This section is empty.

Functions

func DeviceList

func DeviceList(ctx context.Context, cl *kizbox.Client, controllers []string, filter filter.Filter) ([]v1.Device, *http.Response, error)

func DispatchDeviceAction

func DispatchDeviceAction(ctx context.Context, cl *kizbox.Client, logger *zap.Logger, controllers []string, filter filter.Filter, commands ...v1.Command) (*http.Response, error)

Types

type DeviceCmd added in v0.0.2

type DeviceCmd struct {
	List DevicesListCmd `cmd:"list" help:"list devices available"`
	Get  DevicesGetCmd  `cmd:"get" help:"get device by URL"`
}

type DevicesGetCmd added in v0.0.2

type DevicesGetCmd struct {
	URL string `arg:"URL"`
}

func (*DevicesGetCmd) Run added in v0.0.2

func (d *DevicesGetCmd) Run(global *globals.Globals, common *cmd.Commons) error

type DevicesListCmd added in v0.0.2

type DevicesListCmd struct {
	filter.Filter
}

func (*DevicesListCmd) Run added in v0.0.2

func (d *DevicesListCmd) Run(global *globals.Globals, common *cmd.Commons) error

type DiscoverCmd

type DiscoverCmd struct {
	filter.Filter

	Timeout time.Duration `default:"5s" help:"timeout for discovering (ns, ms, s & m)"`
}

func (*DiscoverCmd) Run

func (d *DiscoverCmd) Run(common *cmd.Commons) error

type ListenCmd

type ListenCmd struct {
	Interval time.Duration `help:"Interval between 2 polling (ns, ms, s and m)" default:"5s"`
}

func (ListenCmd) Run

func (l ListenCmd) Run(global *globals.Globals, common *cmd.Commons) error

type VenitianCloseCmd

type VenitianCloseCmd struct{}

func (VenitianCloseCmd) Run

func (s VenitianCloseCmd) Run(global *globals.Globals, common *cmd.Commons, parent *VenitianCmd) error

type VenitianCmd

type VenitianCmd struct {
	filter.Filter
	List  VenitianListCmd  `cmd:"list" help:"List stores. By default, it will list all stores"`
	Set   VenitianSetCmd   `cmd:"set" help:"Set stores. By default, it will set all stores"`
	Open  VenitianOpenCmd  `cmd:"open" help:"Open stores. By default, it will open all stores"`
	Close VenitianCloseCmd `cmd:"close" help:"Close stores. By default, it will close all stores"`
	Wink  VenitianWinkCmd  `cmd:"wink" help:"Wink stores. By default, it will wink all stores"`
	My    VenitianMyCmd    `cmd:"my" help:"Go to my position. By default, it will my all stores"`
}

type VenitianListCmd

type VenitianListCmd struct{}

func (VenitianListCmd) Run

func (s VenitianListCmd) Run(global *globals.Globals, common *cmd.Commons, parent *VenitianCmd) error

type VenitianMyCmd added in v0.0.2

type VenitianMyCmd struct{}

func (VenitianMyCmd) Run added in v0.0.2

func (s VenitianMyCmd) Run(global *globals.Globals, common *cmd.Commons, parent *VenitianCmd) error

type VenitianOpenCmd

type VenitianOpenCmd struct{}

func (VenitianOpenCmd) Run

func (s VenitianOpenCmd) Run(global *globals.Globals, common *cmd.Commons, parent *VenitianCmd) error

type VenitianSetCmd

type VenitianSetCmd struct {
	Position             *int
	Orientation          *int
	Closure              *int
	Name                 *string
	MemorizedPosition    *int
	MemorizedOrientation *int
}

func (VenitianSetCmd) Run

func (s VenitianSetCmd) Run(global *globals.Globals, common *cmd.Commons, parent *VenitianCmd) error

type VenitianWinkCmd added in v0.0.2

type VenitianWinkCmd struct{}

func (VenitianWinkCmd) Run added in v0.0.2

func (s VenitianWinkCmd) Run(global *globals.Globals, common *cmd.Commons, parent *VenitianCmd) error

Jump to

Keyboard shortcuts

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