decoder

package
v1.11.5 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: Apache-2.0 Imports: 1 Imported by: 33

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// NewDecoder creates a new decoder instance.
	NewDecoder = decoder.NewDecoder

	// NewStreamDecoder adapts to encoding/json.NewDecoder API.
	//
	// NewStreamDecoder returns a new decoder that reads from r.
	NewStreamDecoder = decoder.NewStreamDecoder

	// Pretouch compiles vt ahead-of-time to avoid JIT compilation on-the-fly, in
	// order to reduce the first-hit latency.
	//
	// Opts are the compile options, for example, "option.WithCompileRecursiveDepth" is
	// a compile option to set the depth of recursive compile for the nested struct type.
	Pretouch = decoder.Pretouch

	// Skip skips only one json value, and returns first non-blank character position and its ending position if it is valid.
	// Otherwise, returns negative error code using start and invalid character position using end
	Skip = decoder.Skip
)

Functions

This section is empty.

Types

type Decoder

type Decoder = decoder.Decoder

Decoder is the decoder context object

type MismatchTypeError added in v1.6.0

type MismatchTypeError = decoder.MismatchTypeError

MismatchTypeError represents dismatching between json and object

type Options added in v1.3.0

type Options = decoder.Options

Options for decode.

const (
	OptionUseInt64         Options = decoder.OptionUseInt64
	OptionUseNumber        Options = decoder.OptionUseNumber
	OptionUseUnicodeErrors Options = decoder.OptionUseUnicodeErrors
	OptionDisableUnknown   Options = decoder.OptionDisableUnknown
	OptionCopyString       Options = decoder.OptionCopyString
	OptionValidateString   Options = decoder.OptionValidateString
)

type StreamDecoder added in v1.3.0

type StreamDecoder = decoder.StreamDecoder

StreamDecoder is the decoder context object for streaming input.

type SyntaxError

type SyntaxError = decoder.SyntaxError

SyntaxError represents json syntax error

Jump to

Keyboard shortcuts

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