action

package
v0.8.2 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2026 License: AGPL-3.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action interface {
	Invocation() Invocation
	Log() string
}

type Actions

type Actions []Action

func (Actions) MarshalJSON

func (a Actions) MarshalJSON() ([]byte, error)

func (Actions) Set

func (a Actions) Set(h http.Header) error

type Binary

type Binary []byte

type BinaryGZ

type BinaryGZ []byte

type Call

type Call interface {
	Params() CallParams
	Action() (Action, bool)
	Cancel()
	Result(json.RawMessage, error)
}

type CallParams

type CallParams struct {
	Optimistic bool
	Timeout    time.Duration
}

type DoorReplace

type DoorReplace struct {
	ID      uint64
	Payload Payload
}

func (DoorReplace) Invocation

func (a DoorReplace) Invocation() Invocation

func (DoorReplace) Log

func (a DoorReplace) Log() string

type DoorUpdate

type DoorUpdate struct {
	ID      uint64
	Payload Payload
}

func (DoorUpdate) Invocation

func (a DoorUpdate) Invocation() Invocation

func (DoorUpdate) Log

func (a DoorUpdate) Log() string

type DynaRemove

type DynaRemove struct {
	ID uint64
}

func (DynaRemove) Invocation

func (a DynaRemove) Invocation() Invocation

func (DynaRemove) Log

func (a DynaRemove) Log() string

type DynaSet

type DynaSet struct {
	ID    uint64
	Value string
}

func (DynaSet) Invocation

func (a DynaSet) Invocation() Invocation

func (DynaSet) Log

func (a DynaSet) Log() string

type Emit

type Emit struct {
	Name    string
	DoorID  uint64
	Payload Payload
}

func (Emit) Invocation

func (a Emit) Invocation() Invocation

func (Emit) Log

func (a Emit) Log() string

type Indicate

type Indicate struct {
	Duration time.Duration
	Indicate any
}

func (Indicate) Invocation

func (a Indicate) Invocation() Invocation

func (Indicate) Log

func (a Indicate) Log() string

type Invocation

type Invocation struct {
	// contains filtered or unexported fields
}

func (Invocation) Func

func (a Invocation) Func() []any

func (Invocation) MarshalJSON

func (a Invocation) MarshalJSON() ([]byte, error)

func (Invocation) Payload

func (a Invocation) Payload() Payload

type JSON

type JSON []byte

func (JSON) MarshalJSON

func (j JSON) MarshalJSON() ([]byte, error)

type JSONGZ

type JSONGZ []byte

type LocationAssign

type LocationAssign struct {
	URL    string
	Origin bool
}

func (LocationAssign) Invocation

func (a LocationAssign) Invocation() Invocation

func (LocationAssign) Log

func (a LocationAssign) Log() string

type LocationReload

type LocationReload struct{}

func (LocationReload) Invocation

func (a LocationReload) Invocation() Invocation

func (LocationReload) Log

func (a LocationReload) Log() string

type LocationReplace

type LocationReplace struct {
	URL    string
	Origin bool
}

func (LocationReplace) Invocation

func (a LocationReplace) Invocation() Invocation

func (LocationReplace) Log

func (a LocationReplace) Log() string

type Payload

type Payload struct {
	// contains filtered or unexported fields
}

func IntoPayload

func IntoPayload(v any, gz bool) (Payload, error)

func NewBinary

func NewBinary(v []byte) Payload

func NewBinaryGZ

func NewBinaryGZ(v []byte) Payload

func NewEmptyPayload

func NewEmptyPayload() Payload

func NewJSON

func NewJSON(v []byte) Payload

func NewJSONGZ

func NewJSONGZ(v []byte) Payload

func NewNone

func NewNone() Payload

func NewText

func NewText(v string) Payload

func NewTextBytes

func NewTextBytes(text []byte) Payload

func NewTextGZ

func NewTextGZ(v []byte) Payload

func (Payload) IsNone

func (p Payload) IsNone() bool

func (Payload) Len

func (p Payload) Len() int

func (Payload) MarshalJSON

func (p Payload) MarshalJSON() ([]byte, error)

func (Payload) Output

func (p Payload) Output(w io.Writer) error

func (Payload) Type

func (p Payload) Type() PayloadType

type PayloadType

type PayloadType int
const (
	PayloadNone     PayloadType = 0x00
	PayloadBinary   PayloadType = 0x01
	PayloadJSON     PayloadType = 0x02
	PayloadText     PayloadType = 0x03
	PayloadBinaryGZ PayloadType = 0x11
	PayloadJSONGZ   PayloadType = 0x12
	PayloadTextGZ   PayloadType = 0x13
)

type ReportHook

type ReportHook struct {
	HookId uint64
}

func (ReportHook) Invocation

func (a ReportHook) Invocation() Invocation

func (ReportHook) Log

func (a ReportHook) Log() string

type Scroll

type Scroll struct {
	Selector string
	Options  any
}

func (Scroll) Invocation

func (a Scroll) Invocation() Invocation

func (Scroll) Log

func (a Scroll) Log() string

type SetPath

type SetPath struct {
	Path    string
	Replace bool
}

func (SetPath) Invocation

func (a SetPath) Invocation() Invocation

func (SetPath) Log

func (a SetPath) Log() string

type Test

type Test struct {
	Arg any
}

func (Test) Invocation

func (a Test) Invocation() Invocation

func (Test) Log

func (a Test) Log() string

type Text

type Text string

type TextBytes

type TextBytes []byte

func (TextBytes) MarshalJSON

func (t TextBytes) MarshalJSON() ([]byte, error)

type TextGZ

type TextGZ []byte

type UpdateMeta

type UpdateMeta struct {
	Name     string
	Property bool
	Attrs    map[string]string
}

func (UpdateMeta) Invocation

func (u UpdateMeta) Invocation() Invocation

func (UpdateMeta) Log

func (u UpdateMeta) Log() string

type UpdateTitle

type UpdateTitle struct {
	Content string
	Attrs   map[string]string
}

func (UpdateTitle) Invocation

func (u UpdateTitle) Invocation() Invocation

func (UpdateTitle) Log

func (u UpdateTitle) Log() string

Jump to

Keyboard shortcuts

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