Documentation ¶
Index ¶
- Variables
- type Memory
- func (m *Memory) Add(_ context.Context, key, value string) error
- func (m *Memory) Clear(_ context.Context) error
- func (m *Memory) Delete(_ context.Context, key string) error
- func (m *Memory) Get(_ context.Context, key string) (string, error)
- func (m *Memory) GetStoreType(ctx context.Context) string
- func (m *Memory) Keys(_ context.Context, pattern string) ([]string, error)
- type Redis
- func (m *Redis) Add(ctx context.Context, key, value string) error
- func (m *Redis) Clear(ctx context.Context) error
- func (m *Redis) Delete(ctx context.Context, key string) error
- func (m *Redis) Get(ctx context.Context, key string) (string, error)
- func (m *Redis) GetStoreType(ctx context.Context) string
- func (m *Redis) Keys(ctx context.Context, pattern string) ([]string, error)
- type Store
Constants ¶
This section is empty.
Variables ¶
View Source
var ( NotFoundError = errors.New("object not found") AlreadyExistsError = errors.New("object already exists") )
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store interface { Add(ctx context.Context, key, value string) error Get(ctx context.Context, key string) (string, error) Keys(ctx context.Context, pattern string) ([]string, error) Delete(ctx context.Context, key string) error Clear(ctx context.Context) error GetStoreType(ctx context.Context) string }
Click to show internal directories.
Click to hide internal directories.