flagx

package
v0.0.0-...-e560ebb Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2021 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Overview

Package flagx contains extra utilities to complement the flag package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CommaList

func CommaList(s *[]string) flag.Value

CommaList returns a flag.Value that can be passed to flag.Var to parse a comma separated list string into a string slice.

func DeployActionList

func DeployActionList(a *[]dutprep.Action) flag.Value

DeployActionList returns a flag.Value that can be passed to flag.Var to parse a comma separated list string into a dutprep.Action slice.

func JSONMap

func JSONMap(m *map[string]string) flag.Value

JSONMap returns a flag.Value that can be passed to flag.Var to parse a JSON string into a map.

func TaskType

TaskType returns a flag.Value that can be passed to flag.Var for parsing an atutil.AdminTaskType.

Types

type TaskTypeConfig

type TaskTypeConfig int8

TaskTypeConfig is passed to TaskTypeValue to configure parsing.

const (
	RejectNoTask TaskTypeConfig = 1 << iota
	RejectRepair
)

Bit flags for TaskTypeConfig.

Jump to

Keyboard shortcuts

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