udp

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ReadUDP

type ReadUDP interface {
	ReadFromUDP(b []byte) (n int, addr *net.UDPAddr, err error)
	ReadMsgUDP(b, oob []byte) (n, oobn, flags int, addr *net.UDPAddr, err error)
}

type Relay

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

func NewRelay

func NewRelay(pc1, pc2 net.PacketConn) *Relay

func (*Relay) Run

func (r *Relay) Run() (err error)

func (*Relay) SetBufferSize

func (r *Relay) SetBufferSize(n int)

func (*Relay) WithBypass

func (r *Relay) WithBypass(bp bypass.Bypass) *Relay

func (*Relay) WithLogger

func (r *Relay) WithLogger(logger logger.Logger) *Relay

type WriteUDP

type WriteUDP interface {
	WriteToUDP(b []byte, addr *net.UDPAddr) (int, error)
	WriteMsgUDP(b, oob []byte, addr *net.UDPAddr) (n, oobn int, err error)
}

Jump to

Keyboard shortcuts

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