tnet

package
v0.0.0-...-6a56cfb Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Dial

func Dial(t testing.TB, network, address string) net.Conn

func DialIP

func DialIP(t testing.TB, network string, laddr, raddr *net.IPAddr) *net.IPConn

func DialTCP

func DialTCP(t testing.TB, network string, laddr, raddr *net.TCPAddr) *net.TCPConn

func DialTimeout

func DialTimeout(t testing.TB, network, address string, timeout time.Duration) net.Conn

func DialUDP

func DialUDP(t testing.TB, network string, laddr, raddr *net.UDPAddr) *net.UDPConn

func DialUnix

func DialUnix(t testing.TB, network string, laddr, raddr *net.UnixAddr) *net.UnixConn

func FileConn

func FileConn(t testing.TB, f *os.File) (c net.Conn)

func FileListener

func FileListener(t testing.TB, f *os.File) (ln net.Listener)

func FilePacketConn

func FilePacketConn(t testing.TB, f *os.File) (c net.PacketConn)

func InterfaceAddrs

func InterfaceAddrs(t testing.TB) []net.Addr

func InterfaceByIndex

func InterfaceByIndex(t testing.TB, index int) *net.Interface

func InterfaceByName

func InterfaceByName(t testing.TB, name string) *net.Interface

func Interfaces

func Interfaces(t testing.TB) []net.Interface

func Listen

func Listen(t testing.TB, network, address string) net.Listener

func ListenIP

func ListenIP(t testing.TB, network string, laddr *net.IPAddr) *net.IPConn

func ListenMulticastUDP

func ListenMulticastUDP(t testing.TB, network string, ifi *net.Interface, gaddr *net.UDPAddr) *net.UDPConn

func ListenPacket

func ListenPacket(t testing.TB, network, address string) net.PacketConn

func ListenTCP

func ListenTCP(t testing.TB, network string, laddr *net.TCPAddr) *net.TCPListener

func ListenUDP

func ListenUDP(t testing.TB, network string, laddr *net.UDPAddr) *net.UDPConn

func ListenUnix

func ListenUnix(t testing.TB, network string, laddr *net.UnixAddr) *net.UnixListener

func ListenUnixgram

func ListenUnixgram(t testing.TB, network string, laddr *net.UnixAddr) *net.UnixConn

func LookupAddr

func LookupAddr(t testing.TB, addr string) (names []string)

func LookupCNAME

func LookupCNAME(t testing.TB, host string) (cname string)

func LookupHost

func LookupHost(t testing.TB, host string) (addrs []string)

func LookupIP

func LookupIP(t testing.TB, host string) []net.IP

func LookupMX

func LookupMX(t testing.TB, name string) []*net.MX

func LookupNS

func LookupNS(t testing.TB, name string) []*net.NS

func LookupPort

func LookupPort(t testing.TB, network, service string) (port int)

func LookupSRV

func LookupSRV(t testing.TB, service, proto, name string) (cname string, addrs []*net.SRV)

func LookupTXT

func LookupTXT(t testing.TB, name string) []string

func ParseCIDR

func ParseCIDR(t testing.TB, s string) (net.IP, *net.IPNet)

func ParseMAC

func ParseMAC(t testing.TB, s string) (hw net.HardwareAddr)

func ResolveIPAddr

func ResolveIPAddr(t testing.TB, network, address string) *net.IPAddr

func ResolveTCPAddr

func ResolveTCPAddr(t testing.TB, network, address string) *net.TCPAddr

func ResolveUDPAddr

func ResolveUDPAddr(t testing.TB, network, address string) *net.UDPAddr

func ResolveUnixAddr

func ResolveUnixAddr(t testing.TB, network, address string) *net.UnixAddr

func SplitHostPort

func SplitHostPort(t testing.TB, hostport string) (host, port string)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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