udp

package
v0.0.0-...-d31423b Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2019 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Address

type Address struct {
	Addr net.ProtocolAddress
	Port uint16
}

func (Address) Network

func (a Address) Network() string

func (Address) String

func (a Address) String() string

type Conn

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

func Dial

func Dial(local, remote *Address) (*Conn, error)

func Listen

func Listen(local *Address) (*Conn, error)

func (*Conn) Close

func (conn *Conn) Close()

func (*Conn) Read

func (conn *Conn) Read(buf []byte) (int, error)

func (*Conn) ReadFrom

func (conn *Conn) ReadFrom(buf []byte) (int, *Address, error)

func (*Conn) Write

func (conn *Conn) Write(data []byte) error

func (*Conn) WriteTo

func (conn *Conn) WriteTo(data []byte, peer *Address) error

Jump to

Keyboard shortcuts

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