internal

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2019 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StringType = iota
	IntType    = iota
	BoolType   = iota
)

Variables

This section is empty.

Functions

func ParseNonPositional

func ParseNonPositional(params []string, args []Argument) ([]string, error)

func ParsePositional

func ParsePositional(params []string, args []Argument) ([]string, error)

Types

type Argument

type Argument interface {
	GetInfo() ArgumentInfo
	// contains filtered or unexported methods
}

type ArgumentInfo

type ArgumentInfo struct {
	Name        string
	Type        int
	Default     string
	Description string
	Alias       string
}

type IntArgument

type IntArgument struct {
	Variable *int
	Info     ArgumentInfo
}

func (IntArgument) GetInfo

func (arg IntArgument) GetInfo() ArgumentInfo

type Option

type Option struct {
	Variable *bool
	Info     ArgumentInfo
}

func (Option) GetInfo

func (arg Option) GetInfo() ArgumentInfo

type StringArgument

type StringArgument struct {
	Variable *string
	Info     ArgumentInfo
}

func (StringArgument) GetInfo

func (arg StringArgument) GetInfo() ArgumentInfo

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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