tcp

package
v3.50.2 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2018 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PickPort added in v3.11.1

func PickPort() net.Port

PickPort returns an unused TCP port in the system. The port returned is highly likely to be unused, but not guaranteed.

Types

type Server

type Server struct {
	Port         net.Port
	MsgProcessor func(msg []byte) []byte
	ShouldClose  bool
	SendFirst    []byte
	Listen       net.Address
	// contains filtered or unexported fields
}

func (*Server) Close

func (server *Server) Close() error

func (*Server) Start

func (server *Server) Start() (net.Destination, error)

func (*Server) StartContext added in v3.45.1

func (server *Server) StartContext(ctx context.Context) (net.Destination, error)

Jump to

Keyboard shortcuts

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