fusedPacketConn

package
v5.57.2 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2026 License: MIT Imports: 3 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FusedPacketConn

type FusedPacketConn struct {
	// contains filtered or unexported fields
}

FusedPacketConn combines two PacketConn socket to create a dual stack PacketConn When sending packet, the correct PacketConn for that destination address will be chosen When receiving packet, will receive packet from either socket Other operations will be done on both conn

func NewFusedPacketConn

func NewFusedPacketConn(ipv4, ipv6 net.PacketConn, readBufSize int, localAddrPreferIPv6 bool) *FusedPacketConn

func (*FusedPacketConn) Close

func (f *FusedPacketConn) Close() error

func (*FusedPacketConn) LocalAddr

func (f *FusedPacketConn) LocalAddr() net.Addr

func (*FusedPacketConn) ReadFrom

func (f *FusedPacketConn) ReadFrom(p []byte) (int, net.Addr, error)

func (*FusedPacketConn) SetDeadline

func (f *FusedPacketConn) SetDeadline(t time.Time) error

func (*FusedPacketConn) SetReadDeadline

func (f *FusedPacketConn) SetReadDeadline(t time.Time) error

func (*FusedPacketConn) SetWriteDeadline

func (f *FusedPacketConn) SetWriteDeadline(t time.Time) error

func (*FusedPacketConn) WriteTo

func (f *FusedPacketConn) WriteTo(p []byte, addr net.Addr) (int, error)

Jump to

Keyboard shortcuts

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