cli: github.com/cloudfoundry/cli/cf/flags Index | Files

package flags

import "github.com/cloudfoundry/cli/cf/flags"

Index

Package Files

backwards_compatibility.go bool.go flag_constructor.go flags.go flags_usage.go float64.go int.go string.go stringSlice.go

type BackwardsCompatibilityFlag Uses

type BackwardsCompatibilityFlag struct{}

func (*BackwardsCompatibilityFlag) GetName Uses

func (f *BackwardsCompatibilityFlag) GetName() string

func (*BackwardsCompatibilityFlag) GetShortName Uses

func (f *BackwardsCompatibilityFlag) GetShortName() string

func (*BackwardsCompatibilityFlag) GetValue Uses

func (f *BackwardsCompatibilityFlag) GetValue() interface{}

func (*BackwardsCompatibilityFlag) Set Uses

func (f *BackwardsCompatibilityFlag) Set(v string)

func (*BackwardsCompatibilityFlag) String Uses

func (f *BackwardsCompatibilityFlag) String() string

func (*BackwardsCompatibilityFlag) Visible Uses

func (f *BackwardsCompatibilityFlag) Visible() bool

type BoolFlag Uses

type BoolFlag struct {
    Name      string
    Value     bool
    Usage     string
    ShortName string
    Hidden    bool
}

func (*BoolFlag) GetName Uses

func (f *BoolFlag) GetName() string

func (*BoolFlag) GetShortName Uses

func (f *BoolFlag) GetShortName() string

func (*BoolFlag) GetValue Uses

func (f *BoolFlag) GetValue() interface{}

func (*BoolFlag) Set Uses

func (f *BoolFlag) Set(v string)

func (*BoolFlag) String Uses

func (f *BoolFlag) String() string

func (*BoolFlag) Visible Uses

func (f *BoolFlag) Visible() bool

type FlagContext Uses

type FlagContext interface {
    Parse(...string) error
    Args() []string
    Int(string) int
    Float64(string) float64
    Bool(string) bool
    String(string) string
    StringSlice(string) []string
    IsSet(string) bool
    SkipFlagParsing(bool)
    NewStringFlag(name string, shortName string, usage string)
    NewStringFlagWithDefault(name string, shortName string, usage string, value string)
    NewBoolFlag(name string, shortName string, usage string)
    NewIntFlag(name string, shortName string, usage string)
    NewIntFlagWithDefault(name string, shortName string, usage string, value int)
    NewFloat64Flag(name string, shortName string, usage string)
    NewFloat64FlagWithDefault(name string, shortName string, usage string, value float64)
    NewStringSliceFlag(name string, shortName string, usage string)
    NewStringSliceFlagWithDefault(name string, shortName string, usage string, value []string)
    ShowUsage(leadingSpace int) string
}

func New Uses

func New() FlagContext

func NewFlagContext Uses

func NewFlagContext(cmdFlags map[string]FlagSet) FlagContext

type FlagSet Uses

type FlagSet interface {
    fmt.Stringer
    GetName() string
    GetShortName() string
    GetValue() interface{}
    Set(string)
    Visible() bool
}

type Float64Flag Uses

type Float64Flag struct {
    Name      string
    Value     float64
    Usage     string
    ShortName string
    Hidden    bool
}

func (*Float64Flag) GetName Uses

func (f *Float64Flag) GetName() string

func (*Float64Flag) GetShortName Uses

func (f *Float64Flag) GetShortName() string

func (*Float64Flag) GetValue Uses

func (f *Float64Flag) GetValue() interface{}

func (*Float64Flag) Set Uses

func (f *Float64Flag) Set(v string)

func (*Float64Flag) String Uses

func (f *Float64Flag) String() string

func (*Float64Flag) Visible Uses

func (f *Float64Flag) Visible() bool

type IntFlag Uses

type IntFlag struct {
    Name      string
    Value     int
    Usage     string
    ShortName string
    Hidden    bool
}

func (*IntFlag) GetName Uses

func (f *IntFlag) GetName() string

func (*IntFlag) GetShortName Uses

func (f *IntFlag) GetShortName() string

func (*IntFlag) GetValue Uses

func (f *IntFlag) GetValue() interface{}

func (*IntFlag) Set Uses

func (f *IntFlag) Set(v string)

func (*IntFlag) SetVisibility Uses

func (f *IntFlag) SetVisibility(v bool)

func (*IntFlag) String Uses

func (f *IntFlag) String() string

func (*IntFlag) Visible Uses

func (f *IntFlag) Visible() bool

type StringFlag Uses

type StringFlag struct {
    Name      string
    Value     string
    Usage     string
    ShortName string
    Hidden    bool
}

func (*StringFlag) GetName Uses

func (f *StringFlag) GetName() string

func (*StringFlag) GetShortName Uses

func (f *StringFlag) GetShortName() string

func (*StringFlag) GetValue Uses

func (f *StringFlag) GetValue() interface{}

func (*StringFlag) Set Uses

func (f *StringFlag) Set(v string)

func (*StringFlag) String Uses

func (f *StringFlag) String() string

func (*StringFlag) Visible Uses

func (f *StringFlag) Visible() bool

type StringSliceFlag Uses

type StringSliceFlag struct {
    Name      string
    Value     []string
    Usage     string
    ShortName string
    Hidden    bool
}

StringSlice flag can be define multiple times in the arguments

func (*StringSliceFlag) GetName Uses

func (f *StringSliceFlag) GetName() string

func (*StringSliceFlag) GetShortName Uses

func (f *StringSliceFlag) GetShortName() string

func (*StringSliceFlag) GetValue Uses

func (f *StringSliceFlag) GetValue() interface{}

func (*StringSliceFlag) Set Uses

func (f *StringSliceFlag) Set(v string)

func (*StringSliceFlag) String Uses

func (f *StringSliceFlag) String() string

func (*StringSliceFlag) Visible Uses

func (f *StringSliceFlag) Visible() bool

Package flags imports 5 packages (graph) and is imported by 69 packages. Updated 2017-11-28. Refresh now. Tools for package owners.