Documentation ¶
Index ¶
- Variables
- type FS
- func (f *FS) Delete(ctx context.Context, key string) error
- func (f *FS) Read(ctx context.Context, key string) ([]byte, error)
- func (f *FS) ReadStreaming(ctx context.Context, key string) (io.ReadCloser, error)
- func (f *FS) Save(ctx context.Context, key string, content []byte) error
- func (f *FS) SaveStreaming(ctx context.Context, key string) (io.WriteCloser, error)
- type FSOptions
- type Logged
- func (c *Logged) Delete(ctx context.Context, key string) error
- func (c *Logged) Read(ctx context.Context, key string) ([]byte, error)
- func (c *Logged) ReadStreaming(ctx context.Context, key string) (io.ReadCloser, error)
- func (c *Logged) Save(ctx context.Context, key string, content []byte) error
- func (c *Logged) SaveStreaming(ctx context.Context, key string) (io.WriteCloser, error)
- type Memory
- func (m *Memory) Delete(ctx context.Context, key string) error
- func (m *Memory) Read(ctx context.Context, key string) ([]byte, error)
- func (m *Memory) ReadStreaming(ctx context.Context, key string) (io.ReadCloser, error)
- func (m *Memory) Save(ctx context.Context, key string, content []byte) error
- func (m *Memory) SaveStreaming(ctx context.Context, key string) (io.WriteCloser, error)
- type Storage
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrKeyNotFound = errors.New("key not found")
)
Functions ¶
This section is empty.
Types ¶
type FS ¶
type FS struct {
// contains filtered or unexported fields
}
func (*FS) ReadStreaming ¶
func (*FS) SaveStreaming ¶
type Logged ¶
type Logged struct {
// contains filtered or unexported fields
}
func WithLogger ¶
func (*Logged) ReadStreaming ¶
func (*Logged) SaveStreaming ¶
type Memory ¶
type Memory struct {
// contains filtered or unexported fields
}
func (*Memory) ReadStreaming ¶
func (*Memory) SaveStreaming ¶
type Storage ¶
type Storage interface { Read(ctx context.Context, key string) ([]byte, error) ReadStreaming(ctx context.Context, key string) (io.ReadCloser, error) Save(ctx context.Context, key string, content []byte) error SaveStreaming(ctx context.Context, key string) (io.WriteCloser, error) Delete(ctx context.Context, key string) error }
Click to show internal directories.
Click to hide internal directories.