protobuf

package
v0.73.2 Latest Latest
Warning

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

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

Documentation

Overview

Package protobuf is a concrete implementation of the encoding abstractions.

Index

Constants

View Source
const (
	// Type definition.
	Type string = "application/x-protobuf"
	// TypeGoogle definition.
	TypeGoogle string = "application/x-google-protobuf"
)

Variables

This section is empty.

Functions

func Decode

func Decode(data io.Reader, v interface{}) error

Decode a protobuf input in the form of a reader.

func DecodeRaw

func DecodeRaw(data []byte, v interface{}) error

DecodeRaw a protobuf input in the form of a byte slice.

func Encode

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

Encode a model to protobuf.

Types

This section is empty.

Jump to

Keyboard shortcuts

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