quic

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2020 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ReceiveStream

type ReceiveStream interface {
	io.Reader
}

ReceiveStream is an unidirectional Receive Stream.

type SendStream

type SendStream interface {
	io.Writer
	io.Closer
}

A SendStream is an unidirectional Send Stream.

type Server

type Server interface {
	// SetHandler sets QUIC callbacks.
	SetHandler(handler ServerHandler)

	// ListenAndServe starts listening on UDP network address addr and
	// serves incoming packets.
	ListenAndServe(ctx context.Context, addr string) error
}

Server is the QUIC server

func NewServer

func NewServer(handle ServerHandler) Server

NewServer inits the default implementation of QUIC server

type ServerHandler

type ServerHandler interface {
	Read(st Stream) error
}

ServerHandler defines interface to handle the QUIC stream callbacks.

type Stream

type Stream interface {
	ReceiveStream
	SendStream
}

Stream is the QUIC stream

Jump to

Keyboard shortcuts

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