env

package
v0.0.0-...-faf4dc0 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FnDSN        = "dsn"
	FnHost       = "host"
	FnPort       = "port"
	FnSchemaName = "schemaName"
	FnTableName  = "tableName"
	FnBufferSize = "bufferSize"
	FnParameters = "parameters"
	FnDrop       = "drop"
	FnSeparate   = "separate"
	FnWait       = "wait"
)

Flag name constants.

Variables

This section is empty.

Functions

func BufferSize

func BufferSize() int

BufferSize returns the bufferSize command-line flag.

func DSN

func DSN() string

DSN returns the dsn command-line flag.

func Drop

func Drop() bool

Drop returns the drop command-line flag.

func Flags

func Flags() []*flag.Flag

Flags returns a slice containing all command-line flags defined in this package.

func Host

func Host() string

Host returns the host command-line flag.

func Port

func Port() string

Port returns the port command-line flag.

func SchemaName

func SchemaName() string

SchemaName returns the schemaName command-line flag.

func Separate

func Separate() bool

Separate returns the separate command-line flag.

func TableName

func TableName() string

TableName returns the tableName command-line flag.

func Visit

func Visit(f func(f *flag.Flag))

Visit visits the command-line flags defined in this package.

func Wait

func Wait() int

Wait returns the wait command-line flag.

Types

type Prm

type Prm struct {
	BatchCount, BatchSize int
}

Prm represents a test parameter consisting of BatchCount and BatchSize

type PrmValue

type PrmValue struct {
	Prms []Prm
}

PrmValue represents a flag Value fpr parameters.

func Parameters

func Parameters() *PrmValue

Parameters return the parameters command-line flag.

func (*PrmValue) Set

func (v *PrmValue) Set(s string) error

Set implements the flag.Value interface.

func (*PrmValue) String

func (v *PrmValue) String() string

String implements the flag.Value interface.

func (*PrmValue) ToNumRecordList

func (v *PrmValue) ToNumRecordList() [][]Prm

ToNumRecordList returns a list of lists of prms with equal number of records.

Jump to

Keyboard shortcuts

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