emitter

package
v0.0.0-...-33bca21 Latest Latest
Warning

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

Go to latest
Published: May 7, 2015 License: Apache-2.0, Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrorMissingOrigin = errors.New("Event not emitted due to missing origin information")
View Source
var ErrorUnknownEventType = errors.New("Cannot create envelope for unknown event type")

Functions

func NewUdpEmitter

func NewUdpEmitter(remoteAddr string) (*udpEmitter, error)

func Wrap

func Wrap(e events.Event, origin string) (*events.Envelope, error)

Types

type ByteEmitter

type ByteEmitter interface {
	Emit([]byte) error
	Close()
}

type EventEmitter

type EventEmitter interface {
	Emit(events.Event) error
	Close()
}

func NewEventEmitter

func NewEventEmitter(byteEmitter ByteEmitter, origin string) EventEmitter

type InstrumentedEmitter

type InstrumentedEmitter interface {
	ByteEmitter
	GetHeartbeatEvent() events.Event
}

func NewInstrumentedEmitter

func NewInstrumentedEmitter(wrappedEmitter ByteEmitter) (InstrumentedEmitter, error)

type RespondingByteEmitter

type RespondingByteEmitter interface {
	ByteEmitter
	Respond(*control.ControlMessage)
}

func NewHeartbeatResponder

func NewHeartbeatResponder(byteEmitter ByteEmitter, origin string) (RespondingByteEmitter, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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