runtype

package
v0.33.0 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2022 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunTypeStrings

func RunTypeStrings() []string

RunTypeStrings returns a slice of all String values of the enum

Types

type RunType

type RunType int

NOTE: make sure the enum values include and match those in RunType in dcs.pb.go

const (
	NONE RunType = iota
	PHYSICS
	TECHNICAL
	PEDESTAL
	PULSER
	LASER
	CALIBRATION_ITHR_TUNING
	CALIBRATION_VCASN_TUNING
	CALIBRATION_THR_SCAN
	CALIBRATION_DIGITAL_SCAN
	CALIBRATION_ANALOG_SCAN
	CALIBRATION_FHR
	CALIBRATION_ALPIDE_SCAN

	// no correspondence with DCS:
	CALIBRATION
	COSMIC
)

func RunTypeString

func RunTypeString(s string) (RunType, error)

RunTypeString retrieves an enum value from the enum constants string name. Throws an error if the param is not part of the enum.

func RunTypeValues

func RunTypeValues() []RunType

RunTypeValues returns all values of the enum

func (RunType) IsARunType

func (i RunType) IsARunType() bool

IsARunType returns "true" if the value is listed in the enum definition. "false" otherwise

func (RunType) MarshalJSON

func (i RunType) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for RunType

func (RunType) MarshalText

func (i RunType) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for RunType

func (RunType) MarshalYAML

func (i RunType) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for RunType

func (RunType) String

func (i RunType) String() string

func (*RunType) UnmarshalJSON

func (i *RunType) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for RunType

func (*RunType) UnmarshalText

func (i *RunType) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for RunType

func (*RunType) UnmarshalYAML

func (i *RunType) UnmarshalYAML(unmarshal func(interface{}) error) error

UnmarshalYAML implements a YAML Unmarshaler for RunType

Jump to

Keyboard shortcuts

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