package null

import "git.sr.ht/~xn/cache/v2/null"

Index

Types

type Null

type Null[V any] struct{}

Null is empty/stub cache client, usable for testing

func New

func New[V any]() *Null[V]

New creates new stub client

func (*Null[V]) Get

func (c *Null[V]) Get(_ string) V

Get does nothing

func (*Null[V]) Has

func (c *Null[V]) Has(_ string) bool

Has does nothing

func (*Null[V]) Purge

func (c *Null[V]) Purge()

Purge does nothing

func (*Null[V]) Remove

func (c *Null[V]) Remove(_ string)

Remove does nothing

func (*Null[V]) Set

func (c *Null[V]) Set(_ string, _ V)

Set does nothing

Source Files

null.go

Version
v2.1.0 (latest)
Published
Aug 29, 2022
Platform
linux/amd64
Imports
1 packages
Last checked
23 hours ago

Tools for package owners.