netipx

package
v0.22.0 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2025 License: GPL-3.0 Imports: 2 Imported by: 2

Documentation

Overview

Package netipx contains net/netip extensions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddrToAddrPort

func AddrToAddrPort(addr net.Addr) netip.AddrPort

AddrToAddrPort converts a net.Addr to a netip.AddrPort.

If the input is nil or neither a *net.TCPAddr nor *net.UDPAddr, returns an unspecified IPv6 address with port 0.

For *net.TCPAddr and *net.UDPAddr addresses, returns their corresponding netip.AddrPort representation.

Types

This section is empty.

Jump to

Keyboard shortcuts

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