storage

package
v0.0.0-...-cdc1e65 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClipStorageCredentials

type ClipStorageCredentials struct {
	S3 *S3ClipStorageCredentials
}

type ClipStorageInterface

type ClipStorageInterface interface {
	ReadFile(node *common.ClipNode, dest []byte, offset int64) (int, error)
	Metadata() *common.ClipArchiveMetadata
	CachedLocally() bool
}

func NewClipStorage

func NewClipStorage(archivePath string, cachePath string, metadata *common.ClipArchiveMetadata, credentials ClipStorageCredentials) (ClipStorageInterface, error)

type LocalClipStorage

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

func NewLocalClipStorage

func NewLocalClipStorage(metadata *common.ClipArchiveMetadata, opts LocalClipStorageOpts) (*LocalClipStorage, error)

func (*LocalClipStorage) CachedLocally

func (s *LocalClipStorage) CachedLocally() bool

func (*LocalClipStorage) Metadata

func (*LocalClipStorage) ReadFile

func (s *LocalClipStorage) ReadFile(node *common.ClipNode, dest []byte, off int64) (int, error)

type LocalClipStorageOpts

type LocalClipStorageOpts struct {
	ArchivePath string
}

type S3ClipStorage

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

func NewS3ClipStorage

func NewS3ClipStorage(metadata *common.ClipArchiveMetadata, opts S3ClipStorageOpts) (*S3ClipStorage, error)

func (*S3ClipStorage) CachedLocally

func (s3c *S3ClipStorage) CachedLocally() bool

func (*S3ClipStorage) Metadata

func (s3c *S3ClipStorage) Metadata() *common.ClipArchiveMetadata

func (*S3ClipStorage) ReadFile

func (s3c *S3ClipStorage) ReadFile(node *common.ClipNode, dest []byte, off int64) (int, error)

func (*S3ClipStorage) Upload

func (s3c *S3ClipStorage) Upload(archivePath string) error

type S3ClipStorageCredentials

type S3ClipStorageCredentials struct {
	AccessKey string
	SecretKey string
}

type S3ClipStorageOpts

type S3ClipStorageOpts struct {
	Bucket    string
	Key       string
	Region    string
	CachePath string
	AccessKey string
	SecretKey string
}

Jump to

Keyboard shortcuts

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