flags

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2015 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DurationString

func DurationString(dur time.Duration) string

DurationString returns string representation of dur.

Types

type Bind

type Bind struct {
	Host string // available after flag.Parse()
	Port string // available after flag.Parse()
	// contains filtered or unexported fields
}

func NewBind

func NewBind(defport int) Bind

func (*Bind) Set

func (b *Bind) Set(input string) error

func (Bind) String

func (b Bind) String() string

satisfying flag.Value interface

type Delay

type Delay struct {
	time.Duration
	Above *time.Duration // optional
	Below *time.Duration // optional
}

func (Delay) MarshalJSON

func (d Delay) MarshalJSON() ([]byte, error)

MarshalJSON is for encoding/json marshaling into Delay string representation

func (*Delay) Set

func (d *Delay) Set(input string) error

func (Delay) String

func (d Delay) String() string

String returns Delay string representation

type DelayBounds

type DelayBounds struct{ Max, Min Delay }

Jump to

Keyboard shortcuts

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