codegen

package
v0.0.0-...-e303be5 Latest Latest
Warning

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

Go to latest
Published: May 7, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FromContextCurItem

func FromContextCurItem(ctx context.Context) (int, bool)

FromContextCurItem returns the last item flag value stored in ctx, if any.

func FromContextLastItem

func FromContextLastItem(ctx context.Context) (bool, bool)

FromContextLastItem returns the last item flag value stored in ctx, if any.

func NewContextCurItem

func NewContextCurItem(ctx context.Context, u int) context.Context

NewContextCurItem returns a new Context that carries value u.

func NewContextLastItem

func NewContextLastItem(ctx context.Context, u bool) context.Context

NewContextLastItem returns a new Context that carries value u.

func WithEncoding

func WithEncoding(encoding string) utils.WithReaderWriterArgs

Types

type FieldCommons

type FieldCommons[T any] struct {
}

func (FieldCommons[T]) ExtractByteOrder

func (FieldCommons[T]) ExtractByteOrder(readerWriterArgs ...utils.WithReaderWriterArgs) *binary.ByteOrder

func (FieldCommons[T]) SwitchParseByteOrderIfNecessary

func (FieldCommons[T]) SwitchParseByteOrderIfNecessary(ctx context.Context, runnable func(context.Context) (T, error), byteOrderAware utils.ByteOrderAware, wantedByteOrder *binary.ByteOrder) (T, error)

func (FieldCommons[T]) SwitchParseByteOrderIfNecessarySerializeWrapped

func (FieldCommons[T]) SwitchParseByteOrderIfNecessarySerializeWrapped(ctx context.Context, runnable func(context.Context) error, byteOrderAware utils.ByteOrderAware, wantedByteOrder *binary.ByteOrder) error

type PositionMover

type PositionMover interface {
	GetPos() uint16
	SetPos(pos uint16)
}

type WithOption

type WithOption = utils.WithReaderWriterArgs

func WithByteOrder

func WithByteOrder(byteOrder binary.ByteOrder) WithOption

func WithSerializationContext

func WithSerializationContext(context string) WithOption

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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