cflag

package
v0.0.0-...-61e102d Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2016 License: BSD-2-Clause Imports: 3 Imported by: 0

Documentation

Overview

Package cflag is an extension to the standard flag package that brings support of complex types.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Bools

func Bools(name string, value []bool, usage string) *[]bool

Bools is an equivalent of flag.Bool but for []bool value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of a bool slice variable that stores the value of the flag.

func Durations

func Durations(name string, value []time.Duration, usage string) *[]time.Duration

Durations is an equivalent of flag.Duration but for []time.Duration value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of a time.Duration slice variable that stores the value of the flag.

func Float64s

func Float64s(name string, value []float64, usage string) *[]float64

Float64s is an equivalent of flag.Float64 but for []float64 value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of a float64 slice variable that stores the value of the flag.

func Int64s

func Int64s(name string, value []int64, usage string) *[]int64

Int64s is an equivalent of flag.Int64 but for []int64 value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of an int64 slice variable that stores the value of the flag.

func Ints

func Ints(name string, value []int, usage string) *[]int

Ints is an equivalent of flag.Int but for []int value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of an int slice variable that stores the value of the flag.

func Strings

func Strings(name string, value []string, usage string) *[]string

Strings is an equivalent of flag.String but for []string value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of a string slice variable that stores the value of the flag.

func Uint64s

func Uint64s(name string, value []uint64, usage string) *[]uint64

Uint64s is an equivalent of flag.Uint64 but for []uint64 value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of a uint64 slice variable that stores the value of the flag.

func Uints

func Uints(name string, value []uint, usage string) *[]uint

Uints is an equivalent of flag.Uint but for []uint value. It defines a slice flag with the specified name, default value, and usage string. The returned value is the address of a uint slice variable that stores the value of the flag.

Types

This section is empty.

Directories

Path Synopsis
Package types implements flag.Value interface for a number of complex types such as []string, []int, []bool, etc.
Package types implements flag.Value interface for a number of complex types such as []string, []int, []bool, etc.

Jump to

Keyboard shortcuts

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