term

package
v1.11.2 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Log is a updateKind of type Log.
	Log updateKind = iota
	// Logerr is a updateKind of type Logerr.
	Logerr
	// Error is a updateKind of type Error.
	Error
	// Ready is a updateKind of type Ready.
	Ready
	// Restarted is a updateKind of type Restarted.
	Restarted
)

Variables

View Source
var ErrInvalidupdateKind = fmt.Errorf("not a valid updateKind, try [%s]", strings.Join(_updateKindNames, ", "))

Functions

func ParseupdateKind

func ParseupdateKind(name string) (updateKind, error)

ParseupdateKind attempts to convert a string to a updateKind.

func SetContext

func SetContext(ctx context.Context, c *UI) context.Context

SetContext sets the user on the context.

Types

type Component

type Component struct {
	Name string
	// contains filtered or unexported fields
}

func (*Component) Log

func (c *Component) Log(text string)

func (*Component) Logerr

func (c *Component) Logerr(text string)

func (*Component) Ready

func (c *Component) Ready()

func (*Component) Restarted

func (c *Component) Restarted()

type UI

type UI struct {
	deadlock.Mutex
	// contains filtered or unexported fields
}

func ForContext

func ForContext(ctx context.Context) *UI

ForContext finds the Runtime from the context.

func New

func New(debug bool) *UI

func (*UI) Add

func (ui *UI) Add(name string) *Component

func (*UI) Start

func (ui *UI) Start()

func (*UI) Stop

func (ui *UI) Stop()

Jump to

Keyboard shortcuts

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