storage

package
v0.0.0-...-4548471 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LocalDB

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

func NewLocalDB

func NewLocalDB(ttl time.Duration) LocalDB

func (*LocalDB) Close

func (c *LocalDB) Close()

func (*LocalDB) Get

func (c *LocalDB) Get(key string) (string, error)

func (*LocalDB) Put

func (c *LocalDB) Put(key string, data string) error

func (*LocalDB) PutWithTTL

func (c *LocalDB) PutWithTTL(key string, data string, ttl time.Duration) error

type S3Storage

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

func NewS3Storage

func NewS3Storage() S3Storage

func (*S3Storage) Get

func (s *S3Storage) Get(file string) (string, error)

func (*S3Storage) Put

func (s *S3Storage) Put(file string, content string) error

type Storage

type Storage interface {
	Get(file string) (string, error)
	Put(file string, content string) error
}

Jump to

Keyboard shortcuts

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