Documentation
¶
Index ¶
- type ByteNoCache
- type NoCache
- func (n *NoCache[T]) Close() error
- func (n *NoCache[T]) Del(ctx context.Context, key string) error
- func (n *NoCache[T]) DelAll(ctx context.Context) error
- func (n *NoCache[T]) Exists(ctx context.Context, key string) (bool, error)
- func (n *NoCache[T]) Get(ctx context.Context, key string) (T, bool, error)
- func (n *NoCache[T]) MultiDel(ctx context.Context, keys []string) error
- func (n *NoCache[T]) MultiGet(ctx context.Context, keys []string) (map[string]T, error)
- func (n *NoCache[T]) MultiSet(ctx context.Context, valMap map[string]T) error
- func (n *NoCache[T]) MultiSetWithTTL(ctx context.Context, valMap map[string]T, expiration time.Duration) error
- func (n *NoCache[T]) Set(ctx context.Context, key string, val T) error
- func (n *NoCache[T]) SetWithTTL(ctx context.Context, key string, val T, expiration time.Duration) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ByteNoCache ¶
ByteNoCache is a no-operation cache for byte slices.
func NewByteNoCache ¶
func NewByteNoCache() *ByteNoCache
NewByteNoCache creates a new no-operation byte cache.
type NoCache ¶
type NoCache[T any] struct{}
NoCache is a no-operation cache implementation that does not store any data. It implements the Cache interface but all operations are no-ops, useful for disabling caching.
func NewNoCache ¶
NewNoCache creates a new no-operation cache that doesn't actually cache anything.
func (*NoCache[T]) MultiSetWithTTL ¶
Click to show internal directories.
Click to hide internal directories.