Documentation ¶
Index ¶
- Variables
- type Backend
- func (b *Backend) Close(ctx context.Context) error
- func (b *Backend) Create(ctx context.Context, name string) (io.WriteCloser, error)
- func (b *Backend) Open(ctx context.Context, name string) (io.ReadCloser, error)
- func (b *Backend) Provider() string
- func (b *Backend) ReadDir(ctx context.Context, path string) ([]os.FileInfo, error)
- func (b *Backend) Remove(ctx context.Context, key string) error
- func (b *Backend) RemoveAll(ctx context.Context, keys []string) ([]string, error)
- func (b *Backend) Root() string
- func (b *Backend) Walk(ctx context.Context, root string, walkFn filepath.WalkFunc) error
- type Config
- type FileInfo
- type OptionFunc
- type Provider
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DefaultFSRoot = ".saiki" DefaultCloudRoot = "" )
View Source
var ( ProviderMap = map[string]Provider{ string(S3Provider): S3Provider, string(MemProvider): MemProvider, string(FSProvider): FSProvider, } )
View Source
var ( Providers = []string{ string(S3Provider), string(MemProvider), string(FSProvider), } )
Functions ¶
This section is empty.
Types ¶
type Backend ¶
type Backend struct {
// contains filtered or unexported fields
}
type Config ¶
type Config struct { BucketName string Root string S3 *aws.Config Mem *memblob.Options FS *fileblob.Options }
func ConfigFromEnv ¶
type FileInfo ¶
type FileInfo struct {
*blob.ListObject
}
type OptionFunc ¶
type OptionFunc func(*Backend)
func WithConfig ¶
func WithConfig(config Config) OptionFunc
func WithProvider ¶
func WithProvider(provider Provider) OptionFunc
Click to show internal directories.
Click to hide internal directories.