stepsenum

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNoValidEnum = errors.New("not a valid enum")

Functions

This section is empty.

Types

type StepType

type StepType string
const (
	Normal    StepType = "normal"
	Branch    StepType = "branch"
	Boolean   StepType = "boolean"
	Loop      StepType = "loop"
	Condition StepType = "condition"
	Start     StepType = "start"
	End       StepType = "end"
)

func StepTypeFromString

func StepTypeFromString(raw string) (StepType, bool)

StepTypeFromString determines the enum value with an exact case match.

func StepTypeFromStringIgnoreCase

func StepTypeFromStringIgnoreCase(raw string) (StepType, bool)

StepTypeFromStringIgnoreCase determines the enum value with a case-insensitive match.

func (StepType) IsValid

func (_j StepType) IsValid() bool

IsValid tests whether the value is a valid enum value.

func (StepType) MarshalBinary

func (_j StepType) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface for StepType.

func (StepType) MarshalGQL

func (_j StepType) MarshalGQL(w io.Writer)

MarshalGQL implements the graphql.Marshaler interface for StepType.

func (StepType) MarshalJSON

func (_j StepType) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for StepType.

func (StepType) MarshalText

func (_j StepType) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for StepType.

func (StepType) MarshalYAML

func (_j StepType) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for StepType.

func (StepType) SQLTypeName

func (StepType) SQLTypeName() string

func (*StepType) Scan

func (_j *StepType) Scan(value interface{}) error

Scan implements the sql/driver.Scanner interface for StepType.

func (StepType) String

func (_j StepType) String() string

String returns the string of the enum value. If the enum value is invalid, it will produce a string of the following pattern StepType(%d) instead.

func (*StepType) UnmarshalBinary

func (_j *StepType) UnmarshalBinary(text []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface for StepType.

func (*StepType) UnmarshalGQL

func (_j *StepType) UnmarshalGQL(value interface{}) error

UnmarshalGQL implements the graphql.Unmarshaler interface for StepType.

func (*StepType) UnmarshalJSON

func (_j *StepType) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for StepType.

func (*StepType) UnmarshalText

func (_j *StepType) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for StepType.

func (*StepType) UnmarshalYAML

func (_j *StepType) UnmarshalYAML(unmarshal func(interface{}) error) error

UnmarshalYAML implements a YAML Unmarshaler for StepType.

func (StepType) Validate

func (_j StepType) Validate() error

Validate whether the value is within the range of enum values.

func (StepType) Values

func (StepType) Values() []string

Values returns a slice of all String values of the enum.

Jump to

Keyboard shortcuts

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