marshaler

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultMarshaler = &JSONMarshaler{}

Functions

This section is empty.

Types

type JSONMarshaler

type JSONMarshaler struct {
}

JSONMarshaler /**

func (JSONMarshaler) Marshal

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

func (JSONMarshaler) Unmarshal

func (json JSONMarshaler) Unmarshal(data []byte, v interface{}) error

type Marshaler

type Marshaler interface {
	Marshal(v interface{}) ([]byte, error)
	Unmarshal(data []byte, v interface{}) error
}

Marshaler abstraction for marshal and unmarshal

type MsgpackMarshaler

type MsgpackMarshaler struct {
}

MsgpackMarshaler /**

func (MsgpackMarshaler) Marshal

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

func (MsgpackMarshaler) Unmarshal

func (m MsgpackMarshaler) Unmarshal(data []byte, v interface{}) error

Jump to

Keyboard shortcuts

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