blocklist

package
v1.3.7 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlockList

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

BlockList type

func New

func New(cfg *config.Config) *BlockList

New returns a new BlockList

func (*BlockList) Exists

func (b *BlockList) Exists(key string) bool

Exists returns whether or not a key exists in the cache

func (*BlockList) Get

func (b *BlockList) Get(key string) (bool, error)

Get returns the entry for a key or an error

func (*BlockList) Length

func (b *BlockList) Length() int

Length returns the caches length

func (*BlockList) Name

func (b *BlockList) Name() string

Name return middleware name

func (*BlockList) Remove

func (b *BlockList) Remove(key string) bool

Remove removes an entry from the cache

func (*BlockList) ServeDNS

func (b *BlockList) ServeDNS(ctx context.Context, ch *middleware.Chain)

ServeDNS implements the Handle interface.

func (*BlockList) Set

func (b *BlockList) Set(key string) bool

Set sets a value in the BlockList

Jump to

Keyboard shortcuts

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