metathings_deviced_descriptor_storage

package
v1.2.11 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnknownDescriptorStorageDriver = errors.New("unknown descriptor storage driver")
	ErrDescriptorNotFound             = errors.New("descriptor not found")
)

Functions

This section is empty.

Types

type DescriptorStorage

type DescriptorStorage interface {
	SetDescriptor(sha1 string, body []byte) error
	GetDescriptor(sha1 string) ([]byte, error)
}

func NewDescriptorStorage

func NewDescriptorStorage(name string, args ...interface{}) (DescriptorStorage, error)

func NewRedisDescriptorStorage

func NewRedisDescriptorStorage(args ...interface{}) (DescriptorStorage, error)

type DescriptorStorageFactory

type DescriptorStorageFactory func(...interface{}) (DescriptorStorage, error)

type RedisDescriptorStorage

type RedisDescriptorStorage struct {
	// contains filtered or unexported fields
}

func (*RedisDescriptorStorage) GetDescriptor

func (rds *RedisDescriptorStorage) GetDescriptor(sha1 string) ([]byte, error)

func (*RedisDescriptorStorage) SetDescriptor

func (rds *RedisDescriptorStorage) SetDescriptor(sha1 string, body []byte) error

Jump to

Keyboard shortcuts

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