msgpack

package
v2.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2023 License: GPL-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package msgpack provides a msgpack codec

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCodec

func NewCodec(c io.ReadWriteCloser) codec.Codec

Types

type Codec

type Codec struct {
	Conn    io.ReadWriteCloser
	Encoder *msgpack.Encoder
	Decoder *msgpack.Decoder
}

func (*Codec) Close

func (c *Codec) Close() error

func (*Codec) Read

func (c *Codec) Read(b interface{}) error

func (*Codec) String

func (c *Codec) String() string

func (*Codec) Write

func (c *Codec) Write(b interface{}) error

type Marshaler

type Marshaler struct{}

func (Marshaler) Marshal

func (Marshaler) Marshal(v interface{}) ([]byte, error)

func (Marshaler) String

func (Marshaler) String() string

func (Marshaler) Unmarshal

func (Marshaler) Unmarshal(d []byte, v interface{}) error

Jump to

Keyboard shortcuts

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