net

package module
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package net provides generic network helpers and proxies to some useful standard types and functions

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JoinAllHostPorts

func JoinAllHostPorts(addresses []string, ports []uint16) ([]string, error)

JoinAllHostPorts combines a list of addresses and a list of ports, validating the provided IP addresses or name in the process

func JoinHostPort

func JoinHostPort(host string, port uint16) (string, error)

JoinHostPort combines a given host address and a port, validating the provided IP address or name in the process

func SplitHostPort

func SplitHostPort(hostport string) (string, uint16, error)

SplitHostPort splits a network address into host and port, validating the host and port in the process

Types

type Addr

type Addr = net.Addr

Addr is an alias of the standard net.Addr type

type Conn

type Conn = net.Conn

Conn is an alias of the standard net.Conn type

type IP

type IP = net.IP

IP is an alias of the stadnard net.IP type

type Listener

type Listener = net.Listener

Listener is an alias of the standard net.Listener type

Directories

Path Synopsis
Package bind provides mechanisms to facilitate listening TCP and UDP ports
Package bind provides mechanisms to facilitate listening TCP and UDP ports

Jump to

Keyboard shortcuts

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