state

package
v1.16.0 Latest Latest
Warning

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

Go to latest
Published: May 27, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidTransition = fmt.Errorf("invalid cmds")
)

Functions

func NewMachine

func NewMachine() *machine.Machine[Command, State]

Types

type Attr

type Attr = map[string]any

type Candidate

type Candidate struct {
	ID         ID
	Attributes Attr
}

type Canonical

type Canonical struct {
	ID ID
}

type CreateCandidateCMD added in v1.8.0

type CreateCandidateCMD struct {
	ID ID
}

type Duplicate

type Duplicate struct {
	ID          ID
	CanonicalID ID
}

type ID

type ID = string

type MarkAsCanonicalCMD added in v1.8.0

type MarkAsCanonicalCMD struct{}

type MarkAsDuplicateCMD added in v1.8.0

type MarkAsDuplicateCMD struct{ CanonicalID ID }

type MarkAsUniqueCMD added in v1.8.0

type MarkAsUniqueCMD struct{}

type Unique

type Unique struct {
	ID ID
}

Jump to

Keyboard shortcuts

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