cache

package
v0.0.0-...-32b2658 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2024 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrAttached = errors.New("Already attached")

Functions

This section is empty.

Types

type Cache

type Cache struct {
	Path    string
	Timeout time.Duration
	// contains filtered or unexported fields
}

func New

func New(path string) *Cache

func (*Cache) Attach

func (c *Cache) Attach(client *http.Client) error

func (*Cache) AttachDefaultClient

func (c *Cache) AttachDefaultClient() error

func (*Cache) Clear

func (c *Cache) Clear() (freed int64)

func (*Cache) Detach

func (c *Cache) Detach() error

func (*Cache) Purge

func (c *Cache) Purge()

func (*Cache) RoundTrip

func (c *Cache) RoundTrip(req *http.Request) (*http.Response, error)

func (*Cache) Size

func (c *Cache) Size() (size int64)

Jump to

Keyboard shortcuts

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