cidralloc

package
v1.14.1 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CIDRAllocator

type CIDRAllocator interface {
	fmt.Stringer

	Occupy(cidr *net.IPNet) error
	AllocateNext() (*net.IPNet, error)
	Release(cidr *net.IPNet) error
	IsAllocated(cidr *net.IPNet) (bool, error)
	IsFull() bool
	InRange(cidr *net.IPNet) bool
}

func NewCIDRSets

func NewCIDRSets(isV6 bool, strCIDRs []string, maskSize int) ([]CIDRAllocator, error)

type ErrCIDRCollision

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

func (ErrCIDRCollision) Error

func (e ErrCIDRCollision) Error() string

func (*ErrCIDRCollision) Is

func (e *ErrCIDRCollision) Is(target error) bool

Jump to

Keyboard shortcuts

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