netx

package
v0.0.1-alpha Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Address

type Address interface {
	Network() string
	Host() string
	Port() string
	String() string
	HostPort() string
}

func GetFreeAddr

func GetFreeAddr() (Address, error)

GetFreeAddr asks the kernel for a free open port that is ready to use.

type TCPAddress

type TCPAddress struct {
	*net.TCPAddr
}

func (TCPAddress) Host

func (T TCPAddress) Host() string

func (TCPAddress) HostPort

func (T TCPAddress) HostPort() string

func (TCPAddress) Port

func (T TCPAddress) Port() string

func (TCPAddress) String

func (T TCPAddress) String() string

func (TCPAddress) Underlying

func (T TCPAddress) Underlying() net.Addr

Jump to

Keyboard shortcuts

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