generated

package
v0.4.6 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	NilDecode   = errors.New("cannot decode into a nil root struct")
	InvalidEnum = errors.New("invalid enum value")
)

Functions

This section is empty.

Types

type Context

type Context struct {
	ModelField      *EmbeddedModel
	EmptyModelField *EmptyModel

	ModelArrayField      []EmbeddedModel
	EmptyModelArrayField []EmptyModel

	StringField string

	StringArrayField []string

	StringMapField map[string]string

	StringModelMapField map[string]EmbeddedModel

	Int32Field int32

	Int32ArrayField []int32

	Int32MapField map[int32]int32

	Int32MapModelField map[int32]EmbeddedModel

	Int64Field int64

	Int64ArrayField []int64

	Int64MapField map[int64]int64

	Int64MapModelField map[int64]EmbeddedModel

	Uint32Field uint32

	Uint32ArrayField []uint32

	Uint32MapField map[uint32]uint32

	Uint32MapModelField map[uint32]EmbeddedModel

	Uint64Field uint64

	Uint64ArrayField []uint64

	Uint64MapField map[uint64]uint64

	Uint64MapModelField map[uint64]EmbeddedModel

	Float32Field float32

	Float32ArrayField []float32

	Float64Field float64

	Float64ArrayField []float64

	EnumField GenericEnum

	EnumArrayField []GenericEnum

	EnumMapField map[GenericEnum]string

	EnumMapModelField map[GenericEnum]EmbeddedModel

	BytesField []byte

	BytesArrayField [][]byte

	BoolField bool

	BoolArrayField []bool
}

func DecodeContext

func DecodeContext(x *Context, b []byte) (*Context, error)

func NewContext

func NewContext() *Context

func (*Context) Encode

func (x *Context) Encode(b *polyglot.Buffer)

type EmbeddedModel

type EmbeddedModel struct {
	StringField string
}

func DecodeEmbeddedModel

func DecodeEmbeddedModel(x *EmbeddedModel, b []byte) (*EmbeddedModel, error)

func NewEmbeddedModel

func NewEmbeddedModel() *EmbeddedModel

func (*EmbeddedModel) Encode

func (x *EmbeddedModel) Encode(b *polyglot.Buffer)

type EmptyModel

type EmptyModel struct {
}

func DecodeEmptyModel

func DecodeEmptyModel(x *EmptyModel, b []byte) (*EmptyModel, error)

func NewEmptyModel

func NewEmptyModel() *EmptyModel

func (*EmptyModel) Encode

func (x *EmptyModel) Encode(b *polyglot.Buffer)

type GenericEnum

type GenericEnum uint32
const (
	GenericEnumFirstValue GenericEnum = 0

	GenericEnumSecondValue GenericEnum = 1

	GenericEnumDefaultValue GenericEnum = 2
)

Jump to

Keyboard shortcuts

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