serialize

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode[T any](bts SerializedData) (*T, error)

Decode decodes the given serialized data into the given value.

func DecodeInto

func DecodeInto(bts []byte, v any) error

func DecodeSlice

func DecodeSlice[T any](bts []byte) ([]*T, error)

func EncodeSlice

func EncodeSlice[T any](kvs []T) ([]byte, error)

Types

type SerializedData

type SerializedData = []byte

func Encode

func Encode(val any) (SerializedData, error)

Encode encodes the given value into a serialized data format.

Jump to

Keyboard shortcuts

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