enums

package
v0.5.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidPackageStatus = fmt.Errorf("not a valid PackageStatus, try [%s]", strings.Join(_PackageStatusNames, ", "))
View Source
var ErrInvalidPackageType = fmt.Errorf("not a valid PackageType, try [%s]", strings.Join(_PackageTypeNames, ", "))
View Source
var ErrInvalidPreprocessingTaskOutcome = fmt.Errorf("not a valid PreprocessingTaskOutcome, try [%s]", strings.Join(_PreprocessingTaskOutcomeNames, ", "))
View Source
var ErrInvalidPreservationActionStatus = fmt.Errorf("not a valid PreservationActionStatus, try [%s]", strings.Join(_PreservationActionStatusNames, ", "))
View Source
var ErrInvalidPreservationActionType = fmt.Errorf("not a valid PreservationActionType, try [%s]", strings.Join(_PreservationActionTypeNames, ", "))
View Source
var ErrInvalidPreservationTaskStatus = fmt.Errorf("not a valid PreservationTaskStatus, try [%s]", strings.Join(_PreservationTaskStatusNames, ", "))

Functions

func NormalizePackageStatus

func NormalizePackageStatus(name string) string

NormalizePackageStatus attempts to parse a and normalize string as content type. It returns the input untouched if name fails to be parsed. Example:

"enUM" will be normalized (if possible) to "Enum"

func NormalizePackageType

func NormalizePackageType(name string) string

NormalizePackageType attempts to parse a and normalize string as content type. It returns the input untouched if name fails to be parsed. Example:

"enUM" will be normalized (if possible) to "Enum"

func NormalizePreprocessingTaskOutcome

func NormalizePreprocessingTaskOutcome(name string) string

NormalizePreprocessingTaskOutcome attempts to parse a and normalize string as content type. It returns the input untouched if name fails to be parsed. Example:

"enUM" will be normalized (if possible) to "Enum"

func NormalizePreservationActionStatus

func NormalizePreservationActionStatus(name string) string

NormalizePreservationActionStatus attempts to parse a and normalize string as content type. It returns the input untouched if name fails to be parsed. Example:

"enUM" will be normalized (if possible) to "Enum"

func NormalizePreservationActionType

func NormalizePreservationActionType(name string) string

NormalizePreservationActionType attempts to parse a and normalize string as content type. It returns the input untouched if name fails to be parsed. Example:

"enUM" will be normalized (if possible) to "Enum"

func NormalizePreservationTaskStatus

func NormalizePreservationTaskStatus(name string) string

NormalizePreservationTaskStatus attempts to parse a and normalize string as content type. It returns the input untouched if name fails to be parsed. Example:

"enUM" will be normalized (if possible) to "Enum"

func PackageStatusInterfaces

func PackageStatusInterfaces() []interface{}

PackageStatusInterfaces returns an interface list of possible values of PackageStatus.

func PackageStatusNames

func PackageStatusNames() []string

PackageStatusNames returns a list of possible string values of PackageStatus.

func PackageTypeInterfaces

func PackageTypeInterfaces() []interface{}

PackageTypeInterfaces returns an interface list of possible values of PackageType.

func PackageTypeNames

func PackageTypeNames() []string

PackageTypeNames returns a list of possible string values of PackageType.

func PreprocessingTaskOutcomeInterfaces

func PreprocessingTaskOutcomeInterfaces() []interface{}

PreprocessingTaskOutcomeInterfaces returns an interface list of possible values of PreprocessingTaskOutcome.

func PreprocessingTaskOutcomeNames

func PreprocessingTaskOutcomeNames() []string

PreprocessingTaskOutcomeNames returns a list of possible string values of PreprocessingTaskOutcome.

func PreservationActionStatusInterfaces

func PreservationActionStatusInterfaces() []interface{}

PreservationActionStatusInterfaces returns an interface list of possible values of PreservationActionStatus.

func PreservationActionStatusNames

func PreservationActionStatusNames() []string

PreservationActionStatusNames returns a list of possible string values of PreservationActionStatus.

func PreservationActionTypeInterfaces

func PreservationActionTypeInterfaces() []interface{}

PreservationActionTypeInterfaces returns an interface list of possible values of PreservationActionType.

func PreservationActionTypeNames

func PreservationActionTypeNames() []string

PreservationActionTypeNames returns a list of possible string values of PreservationActionType.

func PreservationTaskStatusInterfaces

func PreservationTaskStatusInterfaces() []interface{}

PreservationTaskStatusInterfaces returns an interface list of possible values of PreservationTaskStatus.

func PreservationTaskStatusNames

func PreservationTaskStatusNames() []string

PreservationTaskStatusNames returns a list of possible string values of PreservationTaskStatus.

Types

type PackageStatus

type PackageStatus uint

ENUM( new // Unused! in progress // Undergoing work. done // Work has completed. error // Processing failed. unknown // Unused! queued // Awaiting resource allocation. abandoned // User abandoned processing. pending // Awaiting user decision. )

const (
	// PackageStatusNew is a PackageStatus of type New.
	// Unused!
	PackageStatusNew PackageStatus = iota
	// PackageStatusInProgress is a PackageStatus of type In Progress.
	// Undergoing work.
	PackageStatusInProgress
	// PackageStatusDone is a PackageStatus of type Done.
	// Work has completed.
	PackageStatusDone
	// PackageStatusError is a PackageStatus of type Error.
	// Processing failed.
	PackageStatusError
	// PackageStatusUnknown is a PackageStatus of type Unknown.
	// Unused!
	PackageStatusUnknown
	// PackageStatusQueued is a PackageStatus of type Queued.
	// Awaiting resource allocation.
	PackageStatusQueued
	// PackageStatusAbandoned is a PackageStatus of type Abandoned.
	// User abandoned processing.
	PackageStatusAbandoned
	// PackageStatusPending is a PackageStatus of type Pending.
	// Awaiting user decision.
	PackageStatusPending
)

func ParsePackageStatus

func ParsePackageStatus(name string) (PackageStatus, error)

ParsePackageStatus attempts to convert a string to a PackageStatus.

func ParsePackageStatusWithDefault

func ParsePackageStatusWithDefault(name string) (PackageStatus, error)

ParsePackageStatusWithDefault attempts to convert a string to a ContentType. It returns the default value if name is empty.

func (PackageStatus) IsValid

func (x PackageStatus) IsValid() bool

IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values

func (PackageStatus) String

func (x PackageStatus) String() string

String implements the Stringer interface.

func (PackageStatus) Values

func (x PackageStatus) Values() []string

Values implements the entgo.io/ent/schema/field EnumValues interface.

type PackageType

type PackageType uint

ENUM( Unknown BagIt Archivematica Standard Transfer )

const (
	// PackageTypeUnknown is a PackageType of type Unknown.
	PackageTypeUnknown PackageType = iota
	// PackageTypeBagIt is a PackageType of type BagIt.
	PackageTypeBagIt
	// PackageTypeArchivematicaStandardTransfer is a PackageType of type Archivematica Standard Transfer.
	PackageTypeArchivematicaStandardTransfer
)

func ParsePackageType

func ParsePackageType(name string) (PackageType, error)

ParsePackageType attempts to convert a string to a PackageType.

func ParsePackageTypeWithDefault

func ParsePackageTypeWithDefault(name string) (PackageType, error)

ParsePackageTypeWithDefault attempts to convert a string to a ContentType. It returns the default value if name is empty.

func (PackageType) IsValid

func (x PackageType) IsValid() bool

IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values

func (PackageType) String

func (x PackageType) String() string

String implements the Stringer interface.

func (PackageType) Values

func (x PackageType) Values() []string

Values implements the entgo.io/ent/schema/field EnumValues interface.

type PreprocessingTaskOutcome

type PreprocessingTaskOutcome string

ENUM( unspecified success system failure validation failure )

const (
	// PreprocessingTaskOutcomeUnspecified is a PreprocessingTaskOutcome of type unspecified.
	PreprocessingTaskOutcomeUnspecified PreprocessingTaskOutcome = "unspecified"
	// PreprocessingTaskOutcomeSuccess is a PreprocessingTaskOutcome of type success.
	PreprocessingTaskOutcomeSuccess PreprocessingTaskOutcome = "success"
	// PreprocessingTaskOutcomeSystemFailure is a PreprocessingTaskOutcome of type system failure.
	PreprocessingTaskOutcomeSystemFailure PreprocessingTaskOutcome = "system failure"
	// PreprocessingTaskOutcomeValidationFailure is a PreprocessingTaskOutcome of type validation failure.
	PreprocessingTaskOutcomeValidationFailure PreprocessingTaskOutcome = "validation failure"
)

func ParsePreprocessingTaskOutcome

func ParsePreprocessingTaskOutcome(name string) (PreprocessingTaskOutcome, error)

ParsePreprocessingTaskOutcome attempts to convert a string to a PreprocessingTaskOutcome.

func ParsePreprocessingTaskOutcomeWithDefault

func ParsePreprocessingTaskOutcomeWithDefault(name string) (PreprocessingTaskOutcome, error)

ParsePreprocessingTaskOutcomeWithDefault attempts to convert a string to a ContentType. It returns the default value if name is empty.

func (PreprocessingTaskOutcome) IsValid

func (x PreprocessingTaskOutcome) IsValid() bool

IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values

func (PreprocessingTaskOutcome) String

func (x PreprocessingTaskOutcome) String() string

String implements the Stringer interface.

func (PreprocessingTaskOutcome) Values

func (x PreprocessingTaskOutcome) Values() []string

Values implements the entgo.io/ent/schema/field EnumValues interface.

type PreservationActionStatus

type PreservationActionStatus uint

ENUM( unspecified in progress done error queued pending )

const (
	// PreservationActionStatusUnspecified is a PreservationActionStatus of type Unspecified.
	PreservationActionStatusUnspecified PreservationActionStatus = iota
	// PreservationActionStatusInProgress is a PreservationActionStatus of type In Progress.
	PreservationActionStatusInProgress
	// PreservationActionStatusDone is a PreservationActionStatus of type Done.
	PreservationActionStatusDone
	// PreservationActionStatusError is a PreservationActionStatus of type Error.
	PreservationActionStatusError
	// PreservationActionStatusQueued is a PreservationActionStatus of type Queued.
	PreservationActionStatusQueued
	// PreservationActionStatusPending is a PreservationActionStatus of type Pending.
	PreservationActionStatusPending
)

func ParsePreservationActionStatus

func ParsePreservationActionStatus(name string) (PreservationActionStatus, error)

ParsePreservationActionStatus attempts to convert a string to a PreservationActionStatus.

func ParsePreservationActionStatusWithDefault

func ParsePreservationActionStatusWithDefault(name string) (PreservationActionStatus, error)

ParsePreservationActionStatusWithDefault attempts to convert a string to a ContentType. It returns the default value if name is empty.

func (PreservationActionStatus) IsValid

func (x PreservationActionStatus) IsValid() bool

IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values

func (PreservationActionStatus) String

func (x PreservationActionStatus) String() string

String implements the Stringer interface.

func (PreservationActionStatus) Values

func (x PreservationActionStatus) Values() []string

Values implements the entgo.io/ent/schema/field EnumValues interface.

type PreservationActionType

type PreservationActionType uint

ENUM( unspecified create aip create and review aip move package )

const (
	// PreservationActionTypeUnspecified is a PreservationActionType of type Unspecified.
	PreservationActionTypeUnspecified PreservationActionType = iota
	// PreservationActionTypeCreateAip is a PreservationActionType of type Create Aip.
	PreservationActionTypeCreateAip
	// PreservationActionTypeCreateAndReviewAip is a PreservationActionType of type Create And Review Aip.
	PreservationActionTypeCreateAndReviewAip
	// PreservationActionTypeMovePackage is a PreservationActionType of type Move Package.
	PreservationActionTypeMovePackage
)

func ParsePreservationActionType

func ParsePreservationActionType(name string) (PreservationActionType, error)

ParsePreservationActionType attempts to convert a string to a PreservationActionType.

func ParsePreservationActionTypeWithDefault

func ParsePreservationActionTypeWithDefault(name string) (PreservationActionType, error)

ParsePreservationActionTypeWithDefault attempts to convert a string to a ContentType. It returns the default value if name is empty.

func (PreservationActionType) IsValid

func (x PreservationActionType) IsValid() bool

IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values

func (PreservationActionType) String

func (x PreservationActionType) String() string

String implements the Stringer interface.

func (PreservationActionType) Values

func (x PreservationActionType) Values() []string

Values implements the entgo.io/ent/schema/field EnumValues interface.

type PreservationTaskStatus

type PreservationTaskStatus uint

ENUM( unspecified in progress done error queued pending )

const (
	// PreservationTaskStatusUnspecified is a PreservationTaskStatus of type Unspecified.
	PreservationTaskStatusUnspecified PreservationTaskStatus = iota
	// PreservationTaskStatusInProgress is a PreservationTaskStatus of type In Progress.
	PreservationTaskStatusInProgress
	// PreservationTaskStatusDone is a PreservationTaskStatus of type Done.
	PreservationTaskStatusDone
	// PreservationTaskStatusError is a PreservationTaskStatus of type Error.
	PreservationTaskStatusError
	// PreservationTaskStatusQueued is a PreservationTaskStatus of type Queued.
	PreservationTaskStatusQueued
	// PreservationTaskStatusPending is a PreservationTaskStatus of type Pending.
	PreservationTaskStatusPending
)

func ParsePreservationTaskStatus

func ParsePreservationTaskStatus(name string) (PreservationTaskStatus, error)

ParsePreservationTaskStatus attempts to convert a string to a PreservationTaskStatus.

func ParsePreservationTaskStatusWithDefault

func ParsePreservationTaskStatusWithDefault(name string) (PreservationTaskStatus, error)

ParsePreservationTaskStatusWithDefault attempts to convert a string to a ContentType. It returns the default value if name is empty.

func (PreservationTaskStatus) IsValid

func (x PreservationTaskStatus) IsValid() bool

IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values

func (PreservationTaskStatus) String

func (x PreservationTaskStatus) String() string

String implements the Stringer interface.

func (PreservationTaskStatus) Values

func (x PreservationTaskStatus) Values() []string

Values implements the entgo.io/ent/schema/field EnumValues interface.

Jump to

Keyboard shortcuts

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