actions

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2023 License: GPL-3.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAccessTokenCommand

func NewAccessTokenCommand(global *GlobalAction) *cli.Command

func NewAssertionCommand

func NewAssertionCommand(global *GlobalAction) *cli.Command

func NewGetCommand

func NewGetCommand(global *GlobalAction) *cli.Command

NewGetCommand create a GetAction command.

GetAction retrieves the data for the given url and sends the payload to stdout. Parameters are:

  • server-eori
  • server uri
  • service endpoint, full uri

func NewPostCommand

func NewPostCommand(global *GlobalAction) *cli.Command

NewGetCommand create a PostAction command.

PostAction retrieves the data for the given url and sends the payload to stdout. Parameters are:

  • server-eori
  • server uri
  • service endpoint, full uri
  • data

func NewServeCommand

func NewServeCommand(global *GlobalAction) *cli.Command

func NewTrustedListCommand

func NewTrustedListCommand(global *GlobalAction) *cli.Command

func NewVerifyCommand

func NewVerifyCommand(global *GlobalAction) *cli.Command

func NewVersionCommand

func NewVersionCommand() *cli.Command

Types

type AccessTokenAction

type AccessTokenAction struct {
	*GlobalAction
	// contains filtered or unexported fields
}

func (*AccessTokenAction) Action

func (a *AccessTokenAction) Action(appCtx *cli.Context) error

type App

type App struct {
	*cli.App
	// contains filtered or unexported fields
}

func NewApp

func NewApp() *App

func (*App) Logger

func (a *App) Logger() logr.Logger

func (*App) RunContext

func (a *App) RunContext(ctx context.Context, args []string) error

type AssertionAction

type AssertionAction struct {
	*GlobalAction
	// contains filtered or unexported fields
}

func (*AssertionAction) Action

func (a *AssertionAction) Action(appCtx *cli.Context) error

type GetAction

type GetAction struct {
	*HTTPRequestAction
}

func (*GetAction) Action

func (a *GetAction) Action(appCtx *cli.Context) error

type GlobalAction

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

func (*GlobalAction) Action

func (g *GlobalAction) Action(appCtx *cli.Context) error

Action performs the GlobalAction initialization.

func (*GlobalAction) Flags

func (g *GlobalAction) Flags() []cli.Flag

func (*GlobalAction) LoadCertsAndKeys

func (g *GlobalAction) LoadCertsAndKeys() error

func (*GlobalAction) LogStartupKV

func (g *GlobalAction) LogStartupKV() []interface{}

func (*GlobalAction) Logger

func (g *GlobalAction) Logger() logr.Logger

func (*GlobalAction) SetLogger

func (g *GlobalAction) SetLogger(env string) error

func (*GlobalAction) String

func (g *GlobalAction) String() string

type HTTPRequestAction

type HTTPRequestAction struct {
	*GlobalAction
	// contains filtered or unexported fields
}

func (*HTTPRequestAction) DoRequest

func (a *HTTPRequestAction) DoRequest(req *http.Request) error

func (*HTTPRequestAction) Flags

func (a *HTTPRequestAction) Flags() []cli.Flag

type PostAction

type PostAction struct {
	*HTTPRequestAction
	// contains filtered or unexported fields
}

func (*PostAction) Action

func (a *PostAction) Action(appCtx *cli.Context) error

type ServeAction

type ServeAction struct {
	*GlobalAction
	// contains filtered or unexported fields
}

ServeAction is filled by cli.

It allows for easy testing.

func (*ServeAction) Action

func (a *ServeAction) Action(appCtx *cli.Context) error

func (*ServeAction) Before

func (s *ServeAction) Before(ctx *cli.Context) error

func (*ServeAction) LoadCertsAndKeys

func (a *ServeAction) LoadCertsAndKeys() error

func (*ServeAction) LogStartupKV

func (a *ServeAction) LogStartupKV() []interface{}

func (*ServeAction) String

func (a *ServeAction) String() string

type TrustedListAction

type TrustedListAction struct {
	*GlobalAction
	// contains filtered or unexported fields
}

func (*TrustedListAction) Action

func (a *TrustedListAction) Action(appCtx *cli.Context) error

type VerifyAction

type VerifyAction struct {
	*GlobalAction
}

func (*VerifyAction) Action

func (a *VerifyAction) Action(appCtx *cli.Context) error

type VersionAction

type VersionAction struct {
}

func (*VersionAction) Action

func (a *VersionAction) Action(ctx *cli.Context) error

Jump to

Keyboard shortcuts

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