events

package
v0.0.0-...-832881f Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActionFailed

type ActionFailed struct {
	Context *app.Context
	Config  *configuration.Action
	Error   error
}

func NewActionFailedEvent

func NewActionFailedEvent(context *app.Context, action *configuration.Action, err error) *ActionFailed

type ActionFailedSubscriber

type ActionFailedSubscriber interface {
	Handle(event *ActionFailed) error
}

type ActionSkipped

type ActionSkipped struct {
	Context *app.Context
	Config  *configuration.Action
}

func NewActionSkippedEvent

func NewActionSkippedEvent(context *app.Context, action *configuration.Action) *ActionSkipped

type ActionSkippedSubscriber

type ActionSkippedSubscriber interface {
	Handle(event *ActionSkipped) error
}

type ActionStarted

type ActionStarted struct {
	Context *app.Context
	Config  *configuration.Action
}

func NewActionStartedEvent

func NewActionStartedEvent(context *app.Context, action *configuration.Action) *ActionStarted

type ActionStartedSubscriber

type ActionStartedSubscriber interface {
	Handle(event *ActionStarted) error
}

type ActionSucceeded

type ActionSucceeded struct {
	Context *app.Context
	Config  *configuration.Action
}

func NewActionSucceededEvent

func NewActionSucceededEvent(context *app.Context, action *configuration.Action) *ActionSucceeded

type ActionSucceededSubscriber

type ActionSucceededSubscriber interface {
	Handle(event *ActionSucceeded) error
}

type Dispatcher

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

func NewDispatcher

func NewDispatcher() *Dispatcher

func (*Dispatcher) DispatchActionFailedEvent

func (d *Dispatcher) DispatchActionFailedEvent(event *ActionFailed) error

func (*Dispatcher) DispatchActionSkippedEvent

func (d *Dispatcher) DispatchActionSkippedEvent(event *ActionSkipped) error

func (*Dispatcher) DispatchActionStartedEvent

func (d *Dispatcher) DispatchActionStartedEvent(event *ActionStarted) error

func (*Dispatcher) DispatchActionSucceededEvent

func (d *Dispatcher) DispatchActionSucceededEvent(event *ActionSucceeded) error

func (*Dispatcher) DispatchHookFailedEvent

func (d *Dispatcher) DispatchHookFailedEvent(event *HookFailed) error

func (*Dispatcher) DispatchHookStartedEvent

func (d *Dispatcher) DispatchHookStartedEvent(event *HookStarted) error

func (*Dispatcher) DispatchHookSucceededEvent

func (d *Dispatcher) DispatchHookSucceededEvent(event *HookSucceeded) error

func (*Dispatcher) RegisterActionFailedSubscribers

func (d *Dispatcher) RegisterActionFailedSubscribers(handlers ...ActionFailedSubscriber)

func (*Dispatcher) RegisterActionSkippedSubscribers

func (d *Dispatcher) RegisterActionSkippedSubscribers(handlers ...ActionSkippedSubscriber)

func (*Dispatcher) RegisterActionStartedSubscribers

func (d *Dispatcher) RegisterActionStartedSubscribers(handlers ...ActionStartedSubscriber)

func (*Dispatcher) RegisterActionSucceededSubscribers

func (d *Dispatcher) RegisterActionSucceededSubscribers(handlers ...ActionSucceededSubscriber)

func (*Dispatcher) RegisterHookFailedSubscribers

func (d *Dispatcher) RegisterHookFailedSubscribers(handlers ...HookFailedSubscriber)

func (*Dispatcher) RegisterHookStartedSubscribers

func (d *Dispatcher) RegisterHookStartedSubscribers(handlers ...HookStartedSubscriber)

func (*Dispatcher) RegisterHookSucceededSubscribers

func (d *Dispatcher) RegisterHookSucceededSubscribers(handlers ...HookSucceededSubscriber)

type EventSubscriber

type EventSubscriber interface {
	Subscribe(dispatcher *Dispatcher, action *configuration.Action) error
}

type HookFailed

type HookFailed struct {
	Context  *app.Context
	Config   *configuration.Hook
	Log      *hooks.ActionLog
	ExecTime time.Duration
	Error    error
}

func NewHookFailedEvent

func NewHookFailedEvent(
	context *app.Context,
	hook *configuration.Hook,
	log *hooks.ActionLog,
	execTime time.Duration,
	err error,
) *HookFailed

type HookFailedSubscriber

type HookFailedSubscriber interface {
	Handle(event *HookFailed) error
}

type HookStarted

type HookStarted struct {
	Context *app.Context
	Config  *configuration.Hook
}

func NewHookStartedEvent

func NewHookStartedEvent(context *app.Context, hook *configuration.Hook) *HookStarted

type HookStartedSubscriber

type HookStartedSubscriber interface {
	Handle(event *HookStarted) error
}

type HookSucceeded

type HookSucceeded struct {
	Context  *app.Context
	Config   *configuration.Hook
	Log      *hooks.ActionLog
	ExecTime time.Duration
}

func NewHookSucceededEvent

func NewHookSucceededEvent(
	context *app.Context,
	hook *configuration.Hook,
	log *hooks.ActionLog,
	execTime time.Duration,
) *HookSucceeded

type HookSucceededSubscriber

type HookSucceededSubscriber interface {
	Handle(event *HookSucceeded) error
}

type Subscriber

type Subscriber interface {
	// contains filtered or unexported methods
}

Jump to

Keyboard shortcuts

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