metathings_deviced_descriptor_storage

package
v1.2.7 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2020 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