codec

package
v2022.10.20+incompatible Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrTooLargePacket = errors.New("Too Large Packet")

Functions

func Bufio

func Bufio(base link.Protocol, readBuf, writeBuf int) link.Protocol

Types

type FixLenProtocol

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

func FixLen

func FixLen(base link.Protocol, n int, byteOrder binary.ByteOrder, maxRecv, maxSend int) *FixLenProtocol

func (*FixLenProtocol) NewCodec

func (p *FixLenProtocol) NewCodec(rw io.ReadWriter) (cc link.Codec, err error)

type JsonProtocol

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

func Json

func Json() *JsonProtocol

func (*JsonProtocol) NewCodec

func (j *JsonProtocol) NewCodec(rw io.ReadWriter) (link.Codec, error)

func (*JsonProtocol) Register

func (j *JsonProtocol) Register(t interface{})

func (*JsonProtocol) RegisterName

func (j *JsonProtocol) RegisterName(name string, t interface{})

Jump to

Keyboard shortcuts

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