networkutils

package
v0.6.1 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DefaultNetClient

type DefaultNetClient struct{}

func (*DefaultNetClient) DialTimeout

func (n *DefaultNetClient) DialTimeout(network, address string, timeout time.Duration) (net.Conn, error)

type IPGenerator

type IPGenerator interface {
	GenerateUniqueIP(cidrBlock string) (string, error)
	IsIPUnique(ip string) bool
}

func NewIPGenerator

func NewIPGenerator(netClient NetClient) IPGenerator

type NetClient

type NetClient interface {
	DialTimeout(network, address string, timeout time.Duration) (net.Conn, error)
}

Jump to

Keyboard shortcuts

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