Documentation ¶
Index ¶
- type CacheHandler
- func (ch *CacheHandler) DeleteCache(ctx context.Context, key datastore.Key)
- func (ch *CacheHandler) DeleteMulti(ctx context.Context, keys []datastore.Key) error
- func (ch *CacheHandler) DeleteMultiWithTx(info *datastore.CacheInfo, keys []datastore.Key) error
- func (ch *CacheHandler) DeleteMultiWithoutTx(info *datastore.CacheInfo, keys []datastore.Key) error
- func (ch *CacheHandler) FlushLocalCache()
- func (ch *CacheHandler) GetAll(info *datastore.CacheInfo, q datastore.Query, qDump *datastore.QueryDump, ...) ([]datastore.Key, error)
- func (ch *CacheHandler) GetMulti(ctx context.Context, keys []datastore.Key) ([]*storagecache.CacheItem, error)
- func (ch *CacheHandler) GetMultiWithTx(info *datastore.CacheInfo, keys []datastore.Key, ...) error
- func (ch *CacheHandler) GetMultiWithoutTx(info *datastore.CacheInfo, keys []datastore.Key, ...) error
- func (ch *CacheHandler) Has(key datastore.Key) bool
- func (ch *CacheHandler) Len() int
- func (ch *CacheHandler) Next(info *datastore.CacheInfo, q datastore.Query, qDump *datastore.QueryDump, ...) (datastore.Key, error)
- func (ch *CacheHandler) PostCommit(info *datastore.CacheInfo, tx datastore.Transaction, commit datastore.Commit) error
- func (ch *CacheHandler) PostRollback(info *datastore.CacheInfo, tx datastore.Transaction) error
- func (ch *CacheHandler) Printf(ctx context.Context, format string, args ...interface{})
- func (ch *CacheHandler) PutMultiWithTx(info *datastore.CacheInfo, keys []datastore.Key, ...) ([]datastore.PendingKey, error)
- func (ch *CacheHandler) PutMultiWithoutTx(info *datastore.CacheInfo, keys []datastore.Key, ...) ([]datastore.Key, error)
- func (ch *CacheHandler) Run(info *datastore.CacheInfo, q datastore.Query, qDump *datastore.QueryDump) datastore.Iterator
- func (ch *CacheHandler) SetMulti(ctx context.Context, cis []*storagecache.CacheItem) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CacheHandler ¶
type CacheHandler struct { ExpireDuration time.Duration Logf func(ctx context.Context, format string, args ...interface{}) // contains filtered or unexported fields }
func New ¶
func New(opts ...storagecache.CacheOption) *CacheHandler
func (*CacheHandler) DeleteCache ¶ added in v0.8.0
func (ch *CacheHandler) DeleteCache(ctx context.Context, key datastore.Key)
func (*CacheHandler) DeleteMulti ¶
func (*CacheHandler) DeleteMultiWithTx ¶
func (*CacheHandler) DeleteMultiWithoutTx ¶
func (*CacheHandler) FlushLocalCache ¶
func (ch *CacheHandler) FlushLocalCache()
func (*CacheHandler) GetMulti ¶
func (ch *CacheHandler) GetMulti(ctx context.Context, keys []datastore.Key) ([]*storagecache.CacheItem, error)
func (*CacheHandler) GetMultiWithTx ¶
func (ch *CacheHandler) GetMultiWithTx(info *datastore.CacheInfo, keys []datastore.Key, psList []datastore.PropertyList) error
func (*CacheHandler) GetMultiWithoutTx ¶
func (ch *CacheHandler) GetMultiWithoutTx(info *datastore.CacheInfo, keys []datastore.Key, psList []datastore.PropertyList) error
func (*CacheHandler) Len ¶
func (ch *CacheHandler) Len() int
func (*CacheHandler) PostCommit ¶
func (ch *CacheHandler) PostCommit(info *datastore.CacheInfo, tx datastore.Transaction, commit datastore.Commit) error
func (*CacheHandler) PostRollback ¶
func (ch *CacheHandler) PostRollback(info *datastore.CacheInfo, tx datastore.Transaction) error
func (*CacheHandler) Printf ¶ added in v0.8.2
func (ch *CacheHandler) Printf(ctx context.Context, format string, args ...interface{})
func (*CacheHandler) PutMultiWithTx ¶
func (ch *CacheHandler) PutMultiWithTx(info *datastore.CacheInfo, keys []datastore.Key, psList []datastore.PropertyList) ([]datastore.PendingKey, error)
func (*CacheHandler) PutMultiWithoutTx ¶
func (ch *CacheHandler) PutMultiWithoutTx(info *datastore.CacheInfo, keys []datastore.Key, psList []datastore.PropertyList) ([]datastore.Key, error)
func (*CacheHandler) SetMulti ¶
func (ch *CacheHandler) SetMulti(ctx context.Context, cis []*storagecache.CacheItem) error
Click to show internal directories.
Click to hide internal directories.