listener

package
v0.7.4 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2020 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrAcceptTimeout = errors.New("i/o timeout")
View Source
var ErrNetClosing = errors.New("use of closed network connection")
View Source
var ErrServerClosed = errors.New("server closed")

Functions

func DialContext added in v0.4.7

func DialContext(ctx context.Context, network, address string) (net.Conn, error)

func GetOriginalDestinationAddr added in v0.7.0

func GetOriginalDestinationAddr(conn net.Conn) (net.Addr, error)

func IsAcceptTimeoutError

func IsAcceptTimeoutError(err error) bool

IsAcceptTimeoutError reports whether err is an error from use of a accept timeout.

func IsClosedConnError

func IsClosedConnError(err error) bool

IsClosedConnError reports whether err is an error from use of a closed network connection.

func IsServerClosedError added in v0.7.4

func IsServerClosedError(err error) bool

IsServerClosedError reports whether err is an error from server closed.

func Listen

func Listen(ctx context.Context, network, address string) (net.Listener, error)

func ListenPacket

func ListenPacket(ctx context.Context, network, address string) (net.PacketConn, error)

func NewSingleConnListener

func NewSingleConnListener(conn net.Conn) net.Listener

func VirtualDialContext added in v0.4.7

func VirtualDialContext(ctx context.Context, network, address string) (net.Conn, error)

func VirtualListen added in v0.4.7

func VirtualListen(ctx context.Context, network, address string) (net.Listener, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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