events

package
v0.1.35 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2025 License: GPL-3.0 Imports: 14 Imported by: 1

Documentation

Index

Constants

View Source
const EVENT_CHANGE = "change"
View Source
const EVENT_CHANGED = "changed"
View Source
const EVENT_DELETED = "deleted"
View Source
const EVENT_INSPECT = "inspect"
View Source
const EVENT_RECREATE = "recreate"
View Source
const EVENT_REFRESH = "refresh"
View Source
const EVENT_RESTART = "restart"
View Source
const EVENT_STOP = "stop"
View Source
const EVENT_SYNC = "sync"

Variables

This section is empty.

Functions

func Dispatch added in v0.1.30

func Dispatch(event Event, shared ishared.Shared, node uint64)

func DispatchGroup added in v0.1.30

func DispatchGroup(events []Event, shared ishared.Shared, node uint64)

func Handle

func Handle(kindRegistry map[string]ikinds.Kind, informer *distributed.Informer, event Event, node uint64)

func Listen

func Listen(kindRegistry map[string]ikinds.Kind, e chan KV.KV, informer *distributed.Informer, wss *wss.WebSockets)

Types

type Event

type Event struct {
	Type   string
	Target string
	Prefix string
	Kind   string
	Group  string
	Name   string
	Data   []byte
}

func New

func New(event string, target string, prefix string, kind string, group string, name string, data []byte) Event

func NewKindEvent added in v0.1.30

func NewKindEvent(event string, definition idefinitions.IDefinition, data []byte) Event

func (Event) GetContainerId added in v0.1.30

func (event Event) GetContainerId() string

func (Event) GetData

func (event Event) GetData() []byte

func (Event) GetGroup

func (event Event) GetGroup() string

func (Event) GetKey

func (event Event) GetKey() string

func (Event) GetKind

func (event Event) GetKind() string

func (Event) GetName

func (event Event) GetName() string

func (Event) GetNetworkId added in v0.1.30

func (event Event) GetNetworkId() string

func (Event) GetPrefix added in v0.1.30

func (event Event) GetPrefix() string

func (Event) GetTarget

func (event Event) GetTarget() string

func (Event) GetType

func (event Event) GetType() string

func (Event) IsEmpty added in v0.1.31

func (event Event) IsEmpty() bool

func (Event) IsManaged added in v0.1.30

func (event Event) IsManaged() bool

func (Event) Propose added in v0.1.5

func (event Event) Propose(proposeC *raft.KVStore, node uint64) error

func (Event) SetName added in v0.1.30

func (e Event) SetName(name string) Event

func (Event) ToJson

func (event Event) ToJson() ([]byte, error)

type EventGroup added in v0.1.30

type EventGroup struct {
	Events []Event
}

Jump to

Keyboard shortcuts

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