pills

package
v0.0.0-...-0821d35 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2024 License: BSD-2-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

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

Functions

func PillAliasedStrings

func PillAliasedStrings() []string

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

func PillUnsigned16Strings

func PillUnsigned16Strings() []string

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

func PillUnsigned32Strings

func PillUnsigned32Strings() []string

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

func PillUnsigned64Strings

func PillUnsigned64Strings() []string

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

func PillUnsigned8Strings

func PillUnsigned8Strings() []string

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

func PillUnsignedStrings

func PillUnsignedStrings() []string

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

Types

type PillAliased

type PillAliased PillUnsigned
const (
	PillAliasedPlacebo PillAliased = iota
	PillAliasedAspirin
	PillAliasedIbuprofen
	PillAliasedParacetamol
	PillAliasedAcetaminophen PillAliased = iota - 1
	PillAliasedVitaminC
)

func PillAliasedFromString

func PillAliasedFromString(raw string) (PillAliased, bool)

PillAliasedFromString determines the enum value with an exact case match.

func PillAliasedFromStringIgnoreCase

func PillAliasedFromStringIgnoreCase(raw string) (PillAliased, bool)

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

func PillAliasedValues

func PillAliasedValues() []PillAliased

PillAliasedValues returns all values of the enum.

func (PillAliased) IsValid

func (_p PillAliased) IsValid() bool

IsValid tests whether the value is a valid enum value.

func (PillAliased) MarshalBinary

func (_p PillAliased) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface for PillAliased.

func (PillAliased) MarshalGQL

func (_p PillAliased) MarshalGQL(w io.Writer)

MarshalGQL implements the graphql.Marshaler interface for PillAliased.

func (PillAliased) MarshalJSON

func (_p PillAliased) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for PillAliased.

func (PillAliased) MarshalText

func (_p PillAliased) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for PillAliased.

func (PillAliased) MarshalYAML

func (_p PillAliased) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for PillAliased.

func (*PillAliased) Scan

func (_p *PillAliased) Scan(value interface{}) error

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

func (PillAliased) String

func (_p PillAliased) 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 PillAliased(%d) instead.

func (*PillAliased) UnmarshalBinary

func (_p *PillAliased) UnmarshalBinary(text []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface for PillAliased.

func (*PillAliased) UnmarshalGQL

func (_p *PillAliased) UnmarshalGQL(value interface{}) error

UnmarshalGQL implements the graphql.Unmarshaler interface for PillAliased.

func (*PillAliased) UnmarshalJSON

func (_p *PillAliased) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for PillAliased.

func (*PillAliased) UnmarshalText

func (_p *PillAliased) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for PillAliased.

func (*PillAliased) UnmarshalYAML

func (_p *PillAliased) UnmarshalYAML(n *yaml.Node) error

UnmarshalYAML implements a YAML Unmarshaler for PillAliased.

func (PillAliased) Validate

func (_p PillAliased) Validate() error

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

func (PillAliased) Value

func (_p PillAliased) Value() (driver.Value, error)

Value implements the sql/driver.Valuer interface for PillAliased.

type PillUnsigned

type PillUnsigned uint

Pill with a Doc string.

const (
	PillUnsignedPlacebo PillUnsigned = iota
	PillUnsignedAspirin
	PillUnsignedIbuprofen
	PillUnsignedParacetamol
	PillUnsignedAcetaminophen PillUnsigned = iota - 1
	PillUnsignedVitaminC
)

func PillUnsignedFromString

func PillUnsignedFromString(raw string) (PillUnsigned, bool)

PillUnsignedFromString determines the enum value with an exact case match.

func PillUnsignedFromStringIgnoreCase

func PillUnsignedFromStringIgnoreCase(raw string) (PillUnsigned, bool)

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

func PillUnsignedValues

func PillUnsignedValues() []PillUnsigned

PillUnsignedValues returns all values of the enum.

func (PillUnsigned) IsValid

func (_p PillUnsigned) IsValid() bool

IsValid tests whether the value is a valid enum value.

func (PillUnsigned) MarshalBinary

func (_p PillUnsigned) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface for PillUnsigned.

func (PillUnsigned) MarshalGQL

func (_p PillUnsigned) MarshalGQL(w io.Writer)

MarshalGQL implements the graphql.Marshaler interface for PillUnsigned.

func (PillUnsigned) MarshalJSON

func (_p PillUnsigned) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for PillUnsigned.

func (PillUnsigned) MarshalText

func (_p PillUnsigned) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for PillUnsigned.

func (PillUnsigned) MarshalYAML

func (_p PillUnsigned) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for PillUnsigned.

func (*PillUnsigned) Scan

func (_p *PillUnsigned) Scan(value interface{}) error

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

func (PillUnsigned) String

func (_p PillUnsigned) 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 PillUnsigned(%d) instead.

func (*PillUnsigned) UnmarshalBinary

func (_p *PillUnsigned) UnmarshalBinary(text []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface for PillUnsigned.

func (*PillUnsigned) UnmarshalGQL

func (_p *PillUnsigned) UnmarshalGQL(value interface{}) error

UnmarshalGQL implements the graphql.Unmarshaler interface for PillUnsigned.

func (*PillUnsigned) UnmarshalJSON

func (_p *PillUnsigned) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for PillUnsigned.

func (*PillUnsigned) UnmarshalText

func (_p *PillUnsigned) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for PillUnsigned.

func (*PillUnsigned) UnmarshalYAML

func (_p *PillUnsigned) UnmarshalYAML(n *yaml.Node) error

UnmarshalYAML implements a YAML Unmarshaler for PillUnsigned.

func (PillUnsigned) Validate

func (_p PillUnsigned) Validate() error

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

func (PillUnsigned) Value

func (_p PillUnsigned) Value() (driver.Value, error)

Value implements the sql/driver.Valuer interface for PillUnsigned.

type PillUnsigned16

type PillUnsigned16 uint16
const (
	PillUnsigned16Placebo PillUnsigned16 = iota
	PillUnsigned16Aspirin
	PillUnsigned16Ibuprofen
	PillUnsigned16Paracetamol
	PillUnsigned16Acetaminophen PillUnsigned16 = iota - 1
	PillUnsigned16VitaminC
)

func PillUnsigned16FromString

func PillUnsigned16FromString(raw string) (PillUnsigned16, bool)

PillUnsigned16FromString determines the enum value with an exact case match.

func PillUnsigned16FromStringIgnoreCase

func PillUnsigned16FromStringIgnoreCase(raw string) (PillUnsigned16, bool)

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

func PillUnsigned16Values

func PillUnsigned16Values() []PillUnsigned16

PillUnsigned16Values returns all values of the enum.

func (PillUnsigned16) IsValid

func (_p PillUnsigned16) IsValid() bool

IsValid tests whether the value is a valid enum value.

func (PillUnsigned16) MarshalBinary

func (_p PillUnsigned16) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface for PillUnsigned16.

func (PillUnsigned16) MarshalGQL

func (_p PillUnsigned16) MarshalGQL(w io.Writer)

MarshalGQL implements the graphql.Marshaler interface for PillUnsigned16.

func (PillUnsigned16) MarshalJSON

func (_p PillUnsigned16) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for PillUnsigned16.

func (PillUnsigned16) MarshalText

func (_p PillUnsigned16) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for PillUnsigned16.

func (PillUnsigned16) MarshalYAML

func (_p PillUnsigned16) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for PillUnsigned16.

func (*PillUnsigned16) Scan

func (_p *PillUnsigned16) Scan(value interface{}) error

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

func (PillUnsigned16) String

func (_p PillUnsigned16) 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 PillUnsigned16(%d) instead.

func (*PillUnsigned16) UnmarshalBinary

func (_p *PillUnsigned16) UnmarshalBinary(text []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface for PillUnsigned16.

func (*PillUnsigned16) UnmarshalGQL

func (_p *PillUnsigned16) UnmarshalGQL(value interface{}) error

UnmarshalGQL implements the graphql.Unmarshaler interface for PillUnsigned16.

func (*PillUnsigned16) UnmarshalJSON

func (_p *PillUnsigned16) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for PillUnsigned16.

func (*PillUnsigned16) UnmarshalText

func (_p *PillUnsigned16) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for PillUnsigned16.

func (*PillUnsigned16) UnmarshalYAML

func (_p *PillUnsigned16) UnmarshalYAML(n *yaml.Node) error

UnmarshalYAML implements a YAML Unmarshaler for PillUnsigned16.

func (PillUnsigned16) Validate

func (_p PillUnsigned16) Validate() error

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

func (PillUnsigned16) Value

func (_p PillUnsigned16) Value() (driver.Value, error)

Value implements the sql/driver.Valuer interface for PillUnsigned16.

type PillUnsigned32

type PillUnsigned32 uint32
const (
	PillUnsigned32Placebo PillUnsigned32 = iota
	PillUnsigned32Aspirin
	PillUnsigned32Ibuprofen
	PillUnsigned32Paracetamol
	PillUnsigned32Acetaminophen PillUnsigned32 = iota - 1
	PillUnsigned32VitaminC
)

func PillUnsigned32FromString

func PillUnsigned32FromString(raw string) (PillUnsigned32, bool)

PillUnsigned32FromString determines the enum value with an exact case match.

func PillUnsigned32FromStringIgnoreCase

func PillUnsigned32FromStringIgnoreCase(raw string) (PillUnsigned32, bool)

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

func PillUnsigned32Values

func PillUnsigned32Values() []PillUnsigned32

PillUnsigned32Values returns all values of the enum.

func (PillUnsigned32) IsValid

func (_p PillUnsigned32) IsValid() bool

IsValid tests whether the value is a valid enum value.

func (PillUnsigned32) MarshalBinary

func (_p PillUnsigned32) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface for PillUnsigned32.

func (PillUnsigned32) MarshalGQL

func (_p PillUnsigned32) MarshalGQL(w io.Writer)

MarshalGQL implements the graphql.Marshaler interface for PillUnsigned32.

func (PillUnsigned32) MarshalJSON

func (_p PillUnsigned32) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for PillUnsigned32.

func (PillUnsigned32) MarshalText

func (_p PillUnsigned32) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for PillUnsigned32.

func (PillUnsigned32) MarshalYAML

func (_p PillUnsigned32) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for PillUnsigned32.

func (*PillUnsigned32) Scan

func (_p *PillUnsigned32) Scan(value interface{}) error

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

func (PillUnsigned32) String

func (_p PillUnsigned32) 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 PillUnsigned32(%d) instead.

func (*PillUnsigned32) UnmarshalBinary

func (_p *PillUnsigned32) UnmarshalBinary(text []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface for PillUnsigned32.

func (*PillUnsigned32) UnmarshalGQL

func (_p *PillUnsigned32) UnmarshalGQL(value interface{}) error

UnmarshalGQL implements the graphql.Unmarshaler interface for PillUnsigned32.

func (*PillUnsigned32) UnmarshalJSON

func (_p *PillUnsigned32) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for PillUnsigned32.

func (*PillUnsigned32) UnmarshalText

func (_p *PillUnsigned32) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for PillUnsigned32.

func (*PillUnsigned32) UnmarshalYAML

func (_p *PillUnsigned32) UnmarshalYAML(n *yaml.Node) error

UnmarshalYAML implements a YAML Unmarshaler for PillUnsigned32.

func (PillUnsigned32) Validate

func (_p PillUnsigned32) Validate() error

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

func (PillUnsigned32) Value

func (_p PillUnsigned32) Value() (driver.Value, error)

Value implements the sql/driver.Valuer interface for PillUnsigned32.

type PillUnsigned64

type PillUnsigned64 uint64
const (
	PillUnsigned64Placebo PillUnsigned64 = iota
	PillUnsigned64Aspirin
	PillUnsigned64Ibuprofen
	PillUnsigned64Paracetamol
	PillUnsigned64Acetaminophen PillUnsigned64 = iota - 1
	PillUnsigned64VitaminC
)

func PillUnsigned64FromString

func PillUnsigned64FromString(raw string) (PillUnsigned64, bool)

PillUnsigned64FromString determines the enum value with an exact case match.

func PillUnsigned64FromStringIgnoreCase

func PillUnsigned64FromStringIgnoreCase(raw string) (PillUnsigned64, bool)

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

func PillUnsigned64Values

func PillUnsigned64Values() []PillUnsigned64

PillUnsigned64Values returns all values of the enum.

func (PillUnsigned64) IsValid

func (_p PillUnsigned64) IsValid() bool

IsValid tests whether the value is a valid enum value.

func (PillUnsigned64) MarshalBinary

func (_p PillUnsigned64) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface for PillUnsigned64.

func (PillUnsigned64) MarshalGQL

func (_p PillUnsigned64) MarshalGQL(w io.Writer)

MarshalGQL implements the graphql.Marshaler interface for PillUnsigned64.

func (PillUnsigned64) MarshalJSON

func (_p PillUnsigned64) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for PillUnsigned64.

func (PillUnsigned64) MarshalText

func (_p PillUnsigned64) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for PillUnsigned64.

func (PillUnsigned64) MarshalYAML

func (_p PillUnsigned64) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for PillUnsigned64.

func (*PillUnsigned64) Scan

func (_p *PillUnsigned64) Scan(value interface{}) error

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

func (PillUnsigned64) String

func (_p PillUnsigned64) 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 PillUnsigned64(%d) instead.

func (*PillUnsigned64) UnmarshalBinary

func (_p *PillUnsigned64) UnmarshalBinary(text []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface for PillUnsigned64.

func (*PillUnsigned64) UnmarshalGQL

func (_p *PillUnsigned64) UnmarshalGQL(value interface{}) error

UnmarshalGQL implements the graphql.Unmarshaler interface for PillUnsigned64.

func (*PillUnsigned64) UnmarshalJSON

func (_p *PillUnsigned64) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for PillUnsigned64.

func (*PillUnsigned64) UnmarshalText

func (_p *PillUnsigned64) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for PillUnsigned64.

func (*PillUnsigned64) UnmarshalYAML

func (_p *PillUnsigned64) UnmarshalYAML(n *yaml.Node) error

UnmarshalYAML implements a YAML Unmarshaler for PillUnsigned64.

func (PillUnsigned64) Validate

func (_p PillUnsigned64) Validate() error

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

func (PillUnsigned64) Value

func (_p PillUnsigned64) Value() (driver.Value, error)

Value implements the sql/driver.Valuer interface for PillUnsigned64.

type PillUnsigned8

type PillUnsigned8 uint8
const (
	PillUnsigned8Placebo       PillUnsigned8 = 0
	PillUnsigned8Aspirin       PillUnsigned8 = 1
	PillUnsigned8Ibuprofen     PillUnsigned8 = 2
	PillUnsigned8Paracetamol   PillUnsigned8 = 3
	PillUnsigned8Acetaminophen PillUnsigned8 = PillUnsigned8Paracetamol // hint: fallsback to Paracetamol
	PillUnsigned8VitaminC      PillUnsigned8 = 4
)

func PillUnsigned8FromString

func PillUnsigned8FromString(raw string) (PillUnsigned8, bool)

PillUnsigned8FromString determines the enum value with an exact case match.

func PillUnsigned8FromStringIgnoreCase

func PillUnsigned8FromStringIgnoreCase(raw string) (PillUnsigned8, bool)

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

func PillUnsigned8Values

func PillUnsigned8Values() []PillUnsigned8

PillUnsigned8Values returns all values of the enum.

func (PillUnsigned8) IsValid

func (_p PillUnsigned8) IsValid() bool

IsValid tests whether the value is a valid enum value.

func (PillUnsigned8) MarshalBinary

func (_p PillUnsigned8) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface for PillUnsigned8.

func (PillUnsigned8) MarshalGQL

func (_p PillUnsigned8) MarshalGQL(w io.Writer)

MarshalGQL implements the graphql.Marshaler interface for PillUnsigned8.

func (PillUnsigned8) MarshalJSON

func (_p PillUnsigned8) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface for PillUnsigned8.

func (PillUnsigned8) MarshalText

func (_p PillUnsigned8) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface for PillUnsigned8.

func (PillUnsigned8) MarshalYAML

func (_p PillUnsigned8) MarshalYAML() (interface{}, error)

MarshalYAML implements a YAML Marshaler for PillUnsigned8.

func (*PillUnsigned8) Scan

func (_p *PillUnsigned8) Scan(value interface{}) error

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

func (PillUnsigned8) String

func (_p PillUnsigned8) 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 PillUnsigned8(%d) instead.

func (*PillUnsigned8) UnmarshalBinary

func (_p *PillUnsigned8) UnmarshalBinary(text []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface for PillUnsigned8.

func (*PillUnsigned8) UnmarshalGQL

func (_p *PillUnsigned8) UnmarshalGQL(value interface{}) error

UnmarshalGQL implements the graphql.Unmarshaler interface for PillUnsigned8.

func (*PillUnsigned8) UnmarshalJSON

func (_p *PillUnsigned8) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface for PillUnsigned8.

func (*PillUnsigned8) UnmarshalText

func (_p *PillUnsigned8) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface for PillUnsigned8.

func (*PillUnsigned8) UnmarshalYAML

func (_p *PillUnsigned8) UnmarshalYAML(n *yaml.Node) error

UnmarshalYAML implements a YAML Unmarshaler for PillUnsigned8.

func (PillUnsigned8) Validate

func (_p PillUnsigned8) Validate() error

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

func (PillUnsigned8) Value

func (_p PillUnsigned8) Value() (driver.Value, error)

Value implements the sql/driver.Valuer interface for PillUnsigned8.

Jump to

Keyboard shortcuts

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