alarm

package
v0.0.0-...-76dc376 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2015 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMessage

func NewMessage(alarm bool) interface{}

NewMessage creates a new alarm state update message

Types

type Alarm

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

Alarm is the component that manage the external alarm

func New

func New(alarmHandler types.Enablable) *Alarm

New creates a new Alarm component for an types.Enablable

func (*Alarm) Enabled

func (d *Alarm) Enabled() bool

Enabled is true when the alarm is raised, false otherwise

func (*Alarm) SetInputChan

func (d *Alarm) SetInputChan(c chan interface{})

SetInputChan sets the channel where the alarm updates are sent

func (*Alarm) SetPanicChan

func (d *Alarm) SetPanicChan(c chan interface{})

SetPanicChan sets the channel where this component will send the panics

func (*Alarm) Shutdown

func (d *Alarm) Shutdown()

Shutdown sets all the state to down and notify the handlers

func (*Alarm) Start

func (d *Alarm) Start()

Start the event loop of the Alarm component

Jump to

Keyboard shortcuts

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