action

package
v1.10.2 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2024 License: Apache-2.0 Imports: 18 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 struct {
	Binary    string
	Script    *os.File
	Remote    string
	DelayInMs int
}

func NewLocalAction added in v1.9.0

func NewLocalAction(binary, scriptContent string, delayInMs int) (*Action, error)

func NewRemoteAction added in v1.9.0

func NewRemoteAction(host string, delayInMs int) (*Action, error)

func (*Action) DeleteScript

func (action *Action) DeleteScript() error

func (*Action) Execute added in v1.9.0

func (action *Action) Execute(pair *models.RequestResponsePair, journalIDChannel chan string, journal *journal.Journal) error

func (*Action) GetActionView

func (action *Action) GetActionView(actionName string) v2.ActionView

func (*Action) GetScript

func (action *Action) GetScript() (string, error)

type PostServeActionDetails

type PostServeActionDetails struct {
	Actions        map[string]Action
	FallbackAction *Action
	RWMutex        sync.RWMutex
}

func NewPostServeActionDetails

func NewPostServeActionDetails() *PostServeActionDetails

func (*PostServeActionDetails) DeleteAction

func (postServeActionDetails *PostServeActionDetails) DeleteAction(actionName string) error

func (*PostServeActionDetails) SetAction

func (postServeActionDetails *PostServeActionDetails) SetAction(actionName string, newAction *Action) error

Jump to

Keyboard shortcuts

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