cligw

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: Jan 21, 2024 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 Gateway

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

func NewGateway

func NewGateway() *Gateway

func (*Gateway) Error

func (gateway *Gateway) Error(msg string)

func (Gateway) ErrorWithOpts

func (Gateway) ErrorWithOpts(msg string, opts MsgOpts)

func (*Gateway) Errorf

func (gateway *Gateway) Errorf(msg string, vars ...interface{})

func (*Gateway) ErrorfWithOpts

func (gateway *Gateway) ErrorfWithOpts(msg string, opts MsgOpts, vars ...interface{})

func (*Gateway) Info

func (gateway *Gateway) Info(label, value string)

func (*Gateway) InfoWithOpts

func (gateway *Gateway) InfoWithOpts(label, value string, opts MsgOpts)

func (*Gateway) SelectMany

func (gateway *Gateway) SelectMany(question string, choices SelectChoiceList) ([]SelectChoice, error)

func (*Gateway) SelectManyWithOpts

func (gateway *Gateway) SelectManyWithOpts(question string, choices SelectChoiceList, _ SelectManyOpts) ([]SelectChoice, error)

func (*Gateway) SelectOne

func (gateway *Gateway) SelectOne(question string, choices SelectChoiceList) (*SelectChoice, error)

func (*Gateway) SelectOneWithOpts

func (gateway *Gateway) SelectOneWithOpts(
	question string,
	choices SelectChoiceList,
	opts SelectOneOpts,
) (*SelectChoice, error)

func (*Gateway) Warn

func (gateway *Gateway) Warn(msg string)

func (Gateway) WarnWithOpts

func (Gateway) WarnWithOpts(msg string, opts MsgOpts)

func (*Gateway) Warnf

func (gateway *Gateway) Warnf(msg string, vars ...interface{})

func (*Gateway) WarnfWithOpts

func (gateway *Gateway) WarnfWithOpts(msg string, opts MsgOpts, vars ...interface{})

type MsgOpts

type MsgOpts struct {
	Indent int
}

type SelectChoice

type SelectChoice struct {
	Data  any
	Label string
	Value string
}

type SelectChoiceList

type SelectChoiceList []SelectChoice

func NewSelectChoiceList

func NewSelectChoiceList(values ...string) SelectChoiceList

func (*SelectChoiceList) GetByLabels

func (choiceList *SelectChoiceList) GetByLabels(labels ...string) SelectChoiceList

func (*SelectChoiceList) Labels

func (choiceList *SelectChoiceList) Labels() (result []string)

type SelectManyOpts

type SelectManyOpts struct{}

type SelectOneOpts

type SelectOneOpts struct{ PageLimit *int }

Jump to

Keyboard shortcuts

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