storage

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Jul 4, 2025 License: AGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidStorageType = fmt.Errorf("not a valid StorageType, try [%s]", strings.Join(_StorageTypeNames, ", "))

Functions

func StorageTypeNames

func StorageTypeNames() []string

StorageTypeNames returns a list of possible string values of StorageType.

Types

type StorageType

type StorageType string

StorageType

ENUM(

local, webdav, alist, minio, telegram )

const (
	// Local is a StorageType of type local.
	Local StorageType = "local"
	// Webdav is a StorageType of type webdav.
	Webdav StorageType = "webdav"
	// Alist is a StorageType of type alist.
	Alist StorageType = "alist"
	// Minio is a StorageType of type minio.
	Minio StorageType = "minio"
	// Telegram is a StorageType of type telegram.
	Telegram StorageType = "telegram"
)

func ParseStorageType

func ParseStorageType(name string) (StorageType, error)

ParseStorageType attempts to convert a string to a StorageType.

func StorageTypeValues

func StorageTypeValues() []StorageType

StorageTypeValues returns a list of the values for StorageType

func (*StorageType) Get

func (x *StorageType) Get() interface{}

Get implements the Golang flag.Getter interface func.

func (StorageType) IsValid

func (x StorageType) IsValid() bool

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

func (*StorageType) Set

func (x *StorageType) Set(val string) error

Set implements the Golang flag.Value interface func.

func (StorageType) String

func (x StorageType) String() string

String implements the Stringer interface.

func (*StorageType) Type

func (x *StorageType) Type() string

Type implements the github.com/spf13/pFlag Value interface.

Jump to

Keyboard shortcuts

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