command

package
v0.0.0-...-9be93d0 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ArgTypeBool         = "bool"
	ArgTypeFloat64      = "float64"
	ArgTypeFloat64Slice = "float64_slice"
	ArgTypeInt          = "int"
	ArgTypeIntSlice     = "int_slice"
	ArgTypeInt64        = "int64"
	ArgTypeInt64Slice   = "int64_slice"
	ArgTypeString       = "string"
	ArgTypeStringSlice  = "string_slice"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Arg

type Arg interface {
	Type() string
}

type BoolArg

type BoolArg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    bool
}

func (*BoolArg) Type

func (receiver *BoolArg) Type() string

type BoolFlag

type BoolFlag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    bool
}

func (*BoolFlag) Type

func (receiver *BoolFlag) Type() string

type Extend

type Extend struct {
	Category string
	Flags    []Flag
	Args     []Arg
}

func (Extend) ArgsUsage

func (e Extend) ArgsUsage() string

func (Extend) Validate

func (e Extend) Validate(args []string) (err error)

type Flag

type Flag interface {
	Type() string
}

type Float64Arg

type Float64Arg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    float64
}

func (*Float64Arg) Type

func (receiver *Float64Arg) Type() string

type Float64Flag

type Float64Flag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    float64
}

func (*Float64Flag) Type

func (receiver *Float64Flag) Type() string

type Float64SliceArg

type Float64SliceArg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []float64
}

func (*Float64SliceArg) Type

func (receiver *Float64SliceArg) Type() string

type Float64SliceFlag

type Float64SliceFlag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []float64
}

func (*Float64SliceFlag) Type

func (receiver *Float64SliceFlag) Type() string

type Int64Arg

type Int64Arg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    int64
}

func (*Int64Arg) Type

func (receiver *Int64Arg) Type() string

type Int64Flag

type Int64Flag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    int64
}

func (*Int64Flag) Type

func (receiver *Int64Flag) Type() string

type Int64SliceArg

type Int64SliceArg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []int64
}

func (*Int64SliceArg) Type

func (receiver *Int64SliceArg) Type() string

type Int64SliceFlag

type Int64SliceFlag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []int64
}

func (*Int64SliceFlag) Type

func (receiver *Int64SliceFlag) Type() string

type IntArg

type IntArg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    int
}

func (*IntArg) Type

func (receiver *IntArg) Type() string

type IntFlag

type IntFlag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    int
}

func (*IntFlag) Type

func (receiver *IntFlag) Type() string

type IntSliceArg

type IntSliceArg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []int
}

func (*IntSliceArg) Type

func (receiver *IntSliceArg) Type() string

type IntSliceFlag

type IntSliceFlag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []int
}

func (*IntSliceFlag) Type

func (receiver *IntSliceFlag) Type() string

type StringArg

type StringArg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    string
}

func (*StringArg) Type

func (receiver *StringArg) Type() string

type StringFlag

type StringFlag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    string
}

func (*StringFlag) Type

func (receiver *StringFlag) Type() string

type StringSliceArg

type StringSliceArg struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []string
}

func (*StringSliceArg) Type

func (receiver *StringSliceArg) Type() string

type StringSliceFlag

type StringSliceFlag struct {
	Name     string
	Aliases  []string
	Usage    string
	Required bool
	Value    []string
}

func (*StringSliceFlag) Type

func (receiver *StringSliceFlag) Type() string

Jump to

Keyboard shortcuts

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