Documentation
¶
Index ¶
- func NewBadgerCache(url *url.URL) (cache.Cache, error)
- type BadgerCache
- func (b *BadgerCache) Close() error
- func (b *BadgerCache) Delete(ctx context.Context, key string, opts ...cache.DeleteOptions) error
- func (b *BadgerCache) Exist(ctx context.Context, key string) bool
- func (b *BadgerCache) Get(ctx context.Context, key string) ([]byte, error)
- func (b *BadgerCache) GetFloat(ctx context.Context, key string) (float64, error)
- func (b *BadgerCache) GetInt(ctx context.Context, key string) (int64, error)
- func (b *BadgerCache) GetKeys(ctx context.Context, pattern string) []string
- func (b *BadgerCache) GetObject(ctx context.Context, key string, doc interface{}) error
- func (b *BadgerCache) GetString(ctx context.Context, key string) (string, error)
- func (c *BadgerCache) Increment(ctx context.Context, key string, expiration int) (int64, error)
- func (b *BadgerCache) RemainingTime(ctx context.Context, key string) int
- func (b *BadgerCache) Set(ctx context.Context, key string, value interface{}, expiration int) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BadgerCache ¶
type BadgerCache struct {
// contains filtered or unexported fields
}
func (*BadgerCache) Close ¶
func (b *BadgerCache) Close() error
func (*BadgerCache) Delete ¶
func (b *BadgerCache) Delete(ctx context.Context, key string, opts ...cache.DeleteOptions) error
func (*BadgerCache) GetKeys ¶
func (b *BadgerCache) GetKeys(ctx context.Context, pattern string) []string
func (*BadgerCache) GetObject ¶
func (b *BadgerCache) GetObject(ctx context.Context, key string, doc interface{}) error
func (*BadgerCache) RemainingTime ¶
func (b *BadgerCache) RemainingTime(ctx context.Context, key string) int
Click to show internal directories.
Click to hide internal directories.