state

package
v2.10.1 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2022 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Machine

type Machine map[State]TransitionFunc

Machine is a simple type to hold state machine configuration.

func (Machine) Execute

func (m Machine) Execute(ctx context.Context, obj interface{}, currentState State) (State, error)

type State

type State string

type TransitionFunc

type TransitionFunc func(ctx context.Context, obj interface{}, currentState State) (State, error)

TransitionFunc defines state transition function signature.

Jump to

Keyboard shortcuts

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