addrgen

package
v1.7.3 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddrGen

type AddrGen interface {
	Addr() string
	Power() *big.Int
}

func ParseAddrRangeSpec

func ParseAddrRangeSpec(spec string) (AddrGen, error)

type AddrRange

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

func NewAddrRange

func NewAddrRange(start, end netip.Addr) (*AddrRange, error)

func NewAddrRangeFromPrefix

func NewAddrRangeFromPrefix(pfx netip.Prefix) (*AddrRange, error)

func (*AddrRange) Addr

func (ar *AddrRange) Addr() string

func (*AddrRange) Power

func (ar *AddrRange) Power() *big.Int

type AddrSet

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

func ParseAddrSet

func ParseAddrSet(spec string) (*AddrSet, error)

func (*AddrSet) Endpoint

func (as *AddrSet) Endpoint() string

func (*AddrSet) Power

func (as *AddrSet) Power() *big.Int

type EndpointGen

type EndpointGen interface {
	Endpoint() string
	Power() *big.Int
}

type EqualMultiEndpointGen

type EqualMultiEndpointGen []EndpointGen

func EqualMultiEndpointGenFromSpecs

func EqualMultiEndpointGenFromSpecs(specs []string) (EqualMultiEndpointGen, error)

func NewEqualMultiEndpointGen

func NewEqualMultiEndpointGen(gens ...EndpointGen) (EqualMultiEndpointGen, error)

func (EqualMultiEndpointGen) Endpoint

func (g EqualMultiEndpointGen) Endpoint() string

func (EqualMultiEndpointGen) Power

func (g EqualMultiEndpointGen) Power() *big.Int

type PortGen

type PortGen interface {
	Port() uint16
	Power() uint16
}

func ParsePortRangeSpec

func ParsePortRangeSpec(spec string) (PortGen, error)

type PortRange

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

func NewPortRange

func NewPortRange(start, end uint16) PortRange

func (PortRange) Port

func (p PortRange) Port() uint16

func (PortRange) Power

func (p PortRange) Power() uint16

type SingleAddr

type SingleAddr string

func (SingleAddr) Addr

func (n SingleAddr) Addr() string

func (SingleAddr) Power

func (n SingleAddr) Power() *big.Int

type SingleEndpoint

type SingleEndpoint string

func (SingleEndpoint) Endpoint

func (e SingleEndpoint) Endpoint() string

func (SingleEndpoint) Power

func (e SingleEndpoint) Power() *big.Int

type SinglePort

type SinglePort uint16

func (SinglePort) Port

func (p SinglePort) Port() uint16

func (SinglePort) Power

func (p SinglePort) Power() uint16

Jump to

Keyboard shortcuts

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