cidr

package
v1.18.7 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IpCidrSet

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

func NewIpCidrSet

func NewIpCidrSet() *IpCidrSet

func ReadIpCidrSet added in v1.18.7

func ReadIpCidrSet(r io.Reader) (ss *IpCidrSet, err error)

func (*IpCidrSet) AddIpCidr

func (set *IpCidrSet) AddIpCidr(ipCidr netip.Prefix) (err error)

func (*IpCidrSet) AddIpCidrForString

func (set *IpCidrSet) AddIpCidrForString(ipCidr string) error

func (*IpCidrSet) Foreach added in v1.18.7

func (set *IpCidrSet) Foreach(f func(prefix netip.Prefix) bool)

func (*IpCidrSet) IsContain

func (set *IpCidrSet) IsContain(ip netip.Addr) bool

func (*IpCidrSet) IsContainForString

func (set *IpCidrSet) IsContainForString(ipString string) bool

func (*IpCidrSet) Merge

func (set *IpCidrSet) Merge() error

func (*IpCidrSet) ToIPSet added in v1.18.6

func (set *IpCidrSet) ToIPSet() *netipx.IPSet

ToIPSet not safe convert to *netipx.IPSet be careful, must be used after Merge

func (*IpCidrSet) WriteBin added in v1.18.7

func (ss *IpCidrSet) WriteBin(w io.Writer) (err error)

Jump to

Keyboard shortcuts

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