udp

package
v2.0.95 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2023 License: Apache-2.0 Imports: 15 Imported by: 2

Documentation

Index

Constants

View Source
const Type = "udp"

Variables

This section is empty.

Functions

func Dial

func Dial(destination *net.UDPAddr, name string, _ *identity.TokenId, timeout time.Duration) (transport.Conn, error)

func DialWithLocalBinding

func DialWithLocalBinding(destination *net.UDPAddr, name, localBinding string, timeout time.Duration) (transport.Conn, error)

func Listen

func Listen(bindAddress *net.UDPAddr, name string, i *identity.TokenId, acceptF func(transport.Conn)) (io.Closer, error)

Types

type AddressParser

type AddressParser struct{}

func (AddressParser) Parse

func (ap AddressParser) Parse(s string) (transport.Address, error)

type Connection

type Connection struct {
	net.Conn
	// contains filtered or unexported fields
}

func (*Connection) Detail

func (self *Connection) Detail() *transport.ConnectionDetail

func (*Connection) PeerCertificates

func (self *Connection) PeerCertificates() []*x509.Certificate

func (*Connection) Read

func (self *Connection) Read(p []byte) (n int, err error)

Jump to

Keyboard shortcuts

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