command

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2018 License: MIT Imports: 2 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Command

type Command interface {
	Execute()
	Undo()
}

type Light

type Light struct {
	Site string
}

func (*Light) Off

func (l *Light) Off()

func (*Light) On

func (l *Light) On()

type LightCommand

type LightCommand struct {
	Light *Light
	// contains filtered or unexported fields
}

func (*LightCommand) Execute

func (lc *LightCommand) Execute()

func (*LightCommand) Undo

func (lc *LightCommand) Undo()

type NoCommand

type NoCommand struct {
}

func (*NoCommand) Execute

func (n *NoCommand) Execute()

func (*NoCommand) Undo

func (n *NoCommand) Undo()

type Party

type Party struct {
	Commands []Command
}

func (*Party) Execute

func (p *Party) Execute()

func (*Party) Undo

func (p *Party) Undo()

type RemoteControl

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

func NewRemoteControl

func NewRemoteControl(commandAmount int) *RemoteControl

func (*RemoteControl) Press

func (rc *RemoteControl) Press(i int)

func (*RemoteControl) SetCommand

func (rc *RemoteControl) SetCommand(site int, command Command) error

func (*RemoteControl) UndoPress

func (rc *RemoteControl) UndoPress()

Jump to

Keyboard shortcuts

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