redis

package
v0.0.0-...-e0fbffd Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

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

func NewCache

func NewCache(key string, cl *cs.RedisClient) *Cache

func (*Cache) GetHashAndSize

func (s *Cache) GetHashAndSize() (uint64, int64, error)

func (*Cache) GetSubtitle

func (s *Cache) GetSubtitle(id int, format string) ([]byte, error)

func (*Cache) GetSubtitles

func (s *Cache) GetSubtitles() ([]osdb.Subtitle, error)

func (*Cache) SetHashAndSize

func (s *Cache) SetHashAndSize(hash uint64, size int64) error

func (*Cache) SetSubtitle

func (s *Cache) SetSubtitle(id int, format string, data []byte) error

func (*Cache) SetSubtitles

func (s *Cache) SetSubtitles(subs []osdb.Subtitle) error

type CachePool

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

func NewCachePool

func NewCachePool(cl *cs.RedisClient) *CachePool

func (*CachePool) Get

func (s *CachePool) Get(key string) *Cache

type HashAndSize

type HashAndSize struct {
	Hash uint64
	Size int64
}

Jump to

Keyboard shortcuts

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