observer

package
v1.15.2 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Property

type Property interface {
	Value() any
	Update(any)
	Observe() Stream
}

Property stores a value and allows observers to subscribe to updates.

func NewProperty

func NewProperty(value any) Property

NewProperty creates a property with the provided initial value.

type Stream

type Stream interface {
	Value() any
	Changes() chan struct{}
	Next() any
	WaitNext() any
	HasNext() bool
	Clone() Stream
}

Stream observes updates to a Property.

Jump to

Keyboard shortcuts

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