package encoder

Import Path
	github.com/goccy/go-json/internal/encoder (on go.dev)

Dependency Relation
	imports 19 packages, and imported by 5 packages

Involved Source Files code.go compact.go compiler.go compiler_norace.go context.go decode_rune.go encoder.go indent.go This files's processing codes are inspired by https://github.com/segmentio/encoding. The license notation is as follows. # MIT License Copyright (c) 2019 Segment.io, Inc. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. map113.go opcode.go option.go Code generated by internal/cmd/generator. DO NOT EDIT! query.go This files's string processing codes are inspired by https://github.com/segmentio/encoding. The license notation is as follows. # MIT License Copyright (c) 2019 Segment.io, Inc. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. string_table.go
Package-Level Type Names (total 38)
/* sort by: | */
( AnonymousCode) ToAnonymousOpcode(*compileContext) Opcodes *PtrCode *StructCode
(*ArrayCode) Filter(_ *FieldQuery) Code (*ArrayCode) Kind() CodeKind (*ArrayCode) ToOpcode(ctx *compileContext) Opcodes *ArrayCode : Code
(*BoolCode) Filter(_ *FieldQuery) Code (*BoolCode) Kind() CodeKind (*BoolCode) ToOpcode(ctx *compileContext) Opcodes *BoolCode : Code
(*BytesCode) Filter(_ *FieldQuery) Code (*BytesCode) Kind() CodeKind (*BytesCode) ToOpcode(ctx *compileContext) Opcodes *BytesCode : Code
( Code) Filter(*FieldQuery) Code ( Code) Kind() CodeKind ( Code) ToOpcode(*compileContext) Opcodes *ArrayCode *BoolCode *BytesCode *FloatCode *IntCode *InterfaceCode *MapCode *MarshalJSONCode *MarshalTextCode *PtrCode *SliceCode *StringCode *StructCode *UintCode func (*ArrayCode).Filter(_ *FieldQuery) Code func (*BoolCode).Filter(_ *FieldQuery) Code func (*BytesCode).Filter(_ *FieldQuery) Code func Code.Filter(*FieldQuery) Code func (*FloatCode).Filter(_ *FieldQuery) Code func (*IntCode).Filter(_ *FieldQuery) Code func (*InterfaceCode).Filter(query *FieldQuery) Code func (*MapCode).Filter(_ *FieldQuery) Code func (*MarshalJSONCode).Filter(query *FieldQuery) Code func (*MarshalTextCode).Filter(query *FieldQuery) Code func (*PtrCode).Filter(query *FieldQuery) Code func (*SliceCode).Filter(_ *FieldQuery) Code func (*StringCode).Filter(_ *FieldQuery) Code func (*StructCode).Filter(query *FieldQuery) Code func (*UintCode).Filter(_ *FieldQuery) Code
func (*ArrayCode).Kind() CodeKind func (*BoolCode).Kind() CodeKind func (*BytesCode).Kind() CodeKind func Code.Kind() CodeKind func (*FloatCode).Kind() CodeKind func (*IntCode).Kind() CodeKind func (*InterfaceCode).Kind() CodeKind func (*MapCode).Kind() CodeKind func (*MarshalJSONCode).Kind() CodeKind func (*MarshalTextCode).Kind() CodeKind func (*PtrCode).Kind() CodeKind func (*SliceCode).Kind() CodeKind func (*StringCode).Kind() CodeKind func (*StructCode).Kind() CodeKind func (*UintCode).Kind() CodeKind const CodeKindArray const CodeKindBool const CodeKindBytes const CodeKindFloat const CodeKindInt const CodeKindInterface const CodeKindMap const CodeKindMarshalJSON const CodeKindMarshalText const CodeKindPtr const CodeKindRecursive const CodeKindSlice const CodeKindString const CodeKindStruct const CodeKindUint
func OpType.CodeType() CodeType const CodeArrayElem const CodeArrayHead const CodeMapEnd const CodeMapHead const CodeMapKey const CodeMapValue const CodeOp const CodeRecursive const CodeSliceElem const CodeSliceHead const CodeStructEnd const CodeStructField
type ColorFormat = EncodeFormat (struct)
Code *Opcode CurLen uintptr // whether recursive code already have linked NextLen uintptr
type Compiler (struct)
Footer string Header string
Fields []*FieldQuery Name string (*FieldQuery) Hash() string (*FieldQuery) MarshalJSON() ([]byte, error) (*FieldQuery) QueryString() (FieldQueryString, error) *FieldQuery : github.com/goccy/go-json.Marshaler *FieldQuery : encoding/json.Marshaler func FieldQueryFromContext(ctx context.Context) *FieldQuery func FieldQueryString.Build() (*FieldQuery, error) func SetFieldQueryToContext(ctx context.Context, query *FieldQuery) context.Context func (*ArrayCode).Filter(_ *FieldQuery) Code func (*BoolCode).Filter(_ *FieldQuery) Code func (*BytesCode).Filter(_ *FieldQuery) Code func Code.Filter(*FieldQuery) Code func (*FloatCode).Filter(_ *FieldQuery) Code func (*IntCode).Filter(_ *FieldQuery) Code func (*InterfaceCode).Filter(query *FieldQuery) Code func (*MapCode).Filter(_ *FieldQuery) Code func (*MarshalJSONCode).Filter(query *FieldQuery) Code func (*MarshalTextCode).Filter(query *FieldQuery) Code func (*PtrCode).Filter(query *FieldQuery) Code func (*SliceCode).Filter(_ *FieldQuery) Code func (*StringCode).Filter(_ *FieldQuery) Code func (*StructCode).Filter(query *FieldQuery) Code func (*UintCode).Filter(_ *FieldQuery) Code
( FieldQueryString) Build() (*FieldQuery, error) func (*FieldQuery).QueryString() (FieldQueryString, error)
(*FloatCode) Filter(_ *FieldQuery) Code (*FloatCode) Kind() CodeKind (*FloatCode) ToOpcode(ctx *compileContext) Opcodes *FloatCode : Code
(*IntCode) Filter(_ *FieldQuery) Code (*IntCode) Kind() CodeKind (*IntCode) ToOpcode(ctx *compileContext) Opcodes *IntCode : Code
(*InterfaceCode) Filter(query *FieldQuery) Code (*InterfaceCode) Kind() CodeKind (*InterfaceCode) ToOpcode(ctx *compileContext) Opcodes *InterfaceCode : Code
(*MapCode) Filter(_ *FieldQuery) Code (*MapCode) Kind() CodeKind (*MapCode) ToOpcode(ctx *compileContext) Opcodes *MapCode : Code
Buf []byte First int Idx int Iter mapIter Len int Slice *Mapslice Start int func NewMapContext(mapLen int, unorderedMap bool) *MapContext func ReleaseMapContext(c *MapContext)
Key []byte Value []byte
Items []MapItem (*Mapslice) Len() int (*Mapslice) Less(i, j int) bool (*Mapslice) Swap(i, j int) *Mapslice : sort.Interface
(*MarshalJSONCode) Filter(query *FieldQuery) Code (*MarshalJSONCode) Kind() CodeKind (*MarshalJSONCode) ToOpcode(ctx *compileContext) Opcodes *MarshalJSONCode : Code
(*MarshalTextCode) Filter(query *FieldQuery) Code (*MarshalTextCode) Kind() CodeKind (*MarshalTextCode) ToOpcode(ctx *compileContext) Opcodes *MarshalTextCode : Code
// opcode index // key text to display // offset to access array/slice elem // array/slice/struct/map end // field query for Interface / MarshalJSON / MarshalText Flags OpFlags // offset to access ptr // indent number // for recursive call // struct field key // offset to access slice length or array length // next opcode // next struct field NumBitSize uint8 // offset size from struct header // operation type // pointer number: e.g. double pointer is 2. // array/slice elem size // go type (*Opcode) Dump() string (*Opcode) DumpDOT() string (*Opcode) IsEnd() bool (*Opcode) IterNext() *Opcode (*Opcode) MaxIdx() uint32 (*Opcode) ToFieldType(isString bool) OpType (*Opcode) ToHeaderType(isString bool) OpType (*Opcode) TotalLength() int (*Opcode) Validate() error func ToEndCode(code *Opcode) *Opcode func (*Opcode).IterNext() *Opcode func Opcodes.First() *Opcode func Opcodes.Last() *Opcode func AppendInt(_ *RuntimeContext, out []byte, p uintptr, code *Opcode) []byte func AppendMarshalJSON(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendMarshalJSONIndent(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendMarshalText(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendMarshalTextIndent(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendStructEndIndent(ctx *RuntimeContext, code *Opcode, b []byte) []byte func AppendUint(_ *RuntimeContext, out []byte, p uintptr, code *Opcode) []byte func ErrMarshalerWithCode(code *Opcode, err error) *errors.MarshalerError func ErrUnsupportedValue(code *Opcode, ptr uintptr) *errors.UnsupportedValueError func PtrToInterface(code *Opcode, p uintptr) interface{} func ToEndCode(code *Opcode) *Opcode func Opcodes.Add(codes ...*Opcode) Opcodes
( Opcodes) Add(codes ...*Opcode) Opcodes ( Opcodes) First() *Opcode ( Opcodes) Last() *Opcode func AnonymousCode.ToAnonymousOpcode(*compileContext) Opcodes func (*ArrayCode).ToOpcode(ctx *compileContext) Opcodes func (*BoolCode).ToOpcode(ctx *compileContext) Opcodes func (*BytesCode).ToOpcode(ctx *compileContext) Opcodes func Code.ToOpcode(*compileContext) Opcodes func (*FloatCode).ToOpcode(ctx *compileContext) Opcodes func (*IntCode).ToOpcode(ctx *compileContext) Opcodes func (*InterfaceCode).ToOpcode(ctx *compileContext) Opcodes func (*MapCode).ToOpcode(ctx *compileContext) Opcodes func (*MarshalJSONCode).ToOpcode(ctx *compileContext) Opcodes func (*MarshalTextCode).ToOpcode(ctx *compileContext) Opcodes func Opcodes.Add(codes ...*Opcode) Opcodes func (*PtrCode).ToAnonymousOpcode(ctx *compileContext) Opcodes func (*PtrCode).ToOpcode(ctx *compileContext) Opcodes func (*SliceCode).ToOpcode(ctx *compileContext) Opcodes func (*StringCode).ToOpcode(ctx *compileContext) Opcodes func (*StructCode).ToAnonymousOpcode(ctx *compileContext) Opcodes func (*StructCode).ToOpcode(ctx *compileContext) Opcodes func (*StructFieldCode).ToAnonymousOpcode(ctx *compileContext, isFirstField, isEndField bool) Opcodes func (*StructFieldCode).ToOpcode(ctx *compileContext, isFirstField, isEndField bool) Opcodes func (*UintCode).ToOpcode(ctx *compileContext) Opcodes
Code Code CodeLength int EndCode *Opcode EscapeKeyCode *Opcode InterfaceEscapeKeyCode *Opcode InterfaceNoescapeKeyCode *Opcode NoescapeKeyCode *Opcode QueryCache map[string]*OpcodeSet Type *runtime.Type func CompileToGetCodeSet(ctx *RuntimeContext, typeptr uintptr) (*OpcodeSet, error) func github.com/goccy/go-json/internal/encoder/vm.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color_indent.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color_indent.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_indent.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_indent.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error)
const ColorizeOption const ContextOption const DebugOption const FieldQueryOption const HTMLEscapeOption const IndentOption const NormalizeUTF8Option const UnorderedMapOption
( OpType) CodeType() CodeType ( OpType) FieldToEnd() OpType ( OpType) FieldToOmitEmptyField() OpType ( OpType) HeadToOmitEmptyHead() OpType ( OpType) HeadToPtrHead() OpType ( OpType) IsMultipleOpField() bool ( OpType) IsMultipleOpHead() bool ( OpType) PtrHeadToHead() OpType ( OpType) String() string OpType : expvar.Var OpType : fmt.Stringer func (*Opcode).ToFieldType(isString bool) OpType func (*Opcode).ToHeaderType(isString bool) OpType func OpType.FieldToEnd() OpType func OpType.FieldToOmitEmptyField() OpType func OpType.HeadToOmitEmptyHead() OpType func OpType.HeadToPtrHead() OpType func OpType.PtrHeadToHead() OpType const OpArray const OpArrayElem const OpArrayEnd const OpArrayPtr const OpBool const OpBoolPtr const OpBoolPtrString const OpBoolString const OpBytes const OpBytesPtr const OpEnd const OpFloat32 const OpFloat32Ptr const OpFloat32PtrString const OpFloat32String const OpFloat64 const OpFloat64Ptr const OpFloat64PtrString const OpFloat64String const OpInt const OpInterface const OpInterfaceEnd const OpInterfacePtr const OpIntPtr const OpIntPtrString const OpIntString const OpMap const OpMapEnd const OpMapKey const OpMapPtr const OpMapValue const OpMarshalJSON const OpMarshalJSONPtr const OpMarshalText const OpMarshalTextPtr const OpNumber const OpNumberPtr const OpNumberPtrString const OpNumberString const OpPtr const OpRecursive const OpRecursiveEnd const OpRecursivePtr const OpSlice const OpSliceElem const OpSliceEnd const OpSlicePtr const OpString const OpStringPtr const OpStringPtrString const OpStringString const OpStruct const OpStructEnd const OpStructEndArray const OpStructEndArrayPtr const OpStructEndBool const OpStructEndBoolPtr const OpStructEndBoolPtrString const OpStructEndBoolString const OpStructEndBytes const OpStructEndBytesPtr const OpStructEndFloat32 const OpStructEndFloat32Ptr const OpStructEndFloat32PtrString const OpStructEndFloat32String const OpStructEndFloat64 const OpStructEndFloat64Ptr const OpStructEndFloat64PtrString const OpStructEndFloat64String const OpStructEndInt const OpStructEndInterfacePtr const OpStructEndIntPtr const OpStructEndIntPtrString const OpStructEndIntString const OpStructEndMap const OpStructEndMapPtr const OpStructEndMarshalJSON const OpStructEndMarshalJSONPtr const OpStructEndMarshalText const OpStructEndMarshalTextPtr const OpStructEndNumber const OpStructEndNumberPtr const OpStructEndNumberPtrString const OpStructEndNumberString const OpStructEndOmitEmpty const OpStructEndOmitEmptyArray const OpStructEndOmitEmptyArrayPtr const OpStructEndOmitEmptyBool const OpStructEndOmitEmptyBoolPtr const OpStructEndOmitEmptyBoolPtrString const OpStructEndOmitEmptyBoolString const OpStructEndOmitEmptyBytes const OpStructEndOmitEmptyBytesPtr const OpStructEndOmitEmptyFloat32 const OpStructEndOmitEmptyFloat32Ptr const OpStructEndOmitEmptyFloat32PtrString const OpStructEndOmitEmptyFloat32String const OpStructEndOmitEmptyFloat64 const OpStructEndOmitEmptyFloat64Ptr const OpStructEndOmitEmptyFloat64PtrString const OpStructEndOmitEmptyFloat64String const OpStructEndOmitEmptyInt const OpStructEndOmitEmptyInterfacePtr const OpStructEndOmitEmptyIntPtr const OpStructEndOmitEmptyIntPtrString const OpStructEndOmitEmptyIntString const OpStructEndOmitEmptyMap const OpStructEndOmitEmptyMapPtr const OpStructEndOmitEmptyMarshalJSON const OpStructEndOmitEmptyMarshalJSONPtr const OpStructEndOmitEmptyMarshalText const OpStructEndOmitEmptyMarshalTextPtr const OpStructEndOmitEmptyNumber const OpStructEndOmitEmptyNumberPtr const OpStructEndOmitEmptyNumberPtrString const OpStructEndOmitEmptyNumberString const OpStructEndOmitEmptySlice const OpStructEndOmitEmptySlicePtr const OpStructEndOmitEmptyString const OpStructEndOmitEmptyStringPtr const OpStructEndOmitEmptyStringPtrString const OpStructEndOmitEmptyStringString const OpStructEndOmitEmptyStruct const OpStructEndOmitEmptyUint const OpStructEndOmitEmptyUintPtr const OpStructEndOmitEmptyUintPtrString const OpStructEndOmitEmptyUintString const OpStructEndSlice const OpStructEndSlicePtr const OpStructEndString const OpStructEndStringPtr const OpStructEndStringPtrString const OpStructEndStringString const OpStructEndStruct const OpStructEndUint const OpStructEndUintPtr const OpStructEndUintPtrString const OpStructEndUintString const OpStructField const OpStructFieldArray const OpStructFieldArrayPtr const OpStructFieldBool const OpStructFieldBoolPtr const OpStructFieldBoolPtrString const OpStructFieldBoolString const OpStructFieldBytes const OpStructFieldBytesPtr const OpStructFieldFloat32 const OpStructFieldFloat32Ptr const OpStructFieldFloat32PtrString const OpStructFieldFloat32String const OpStructFieldFloat64 const OpStructFieldFloat64Ptr const OpStructFieldFloat64PtrString const OpStructFieldFloat64String const OpStructFieldInt const OpStructFieldInterfacePtr const OpStructFieldIntPtr const OpStructFieldIntPtrString const OpStructFieldIntString const OpStructFieldMap const OpStructFieldMapPtr const OpStructFieldMarshalJSON const OpStructFieldMarshalJSONPtr const OpStructFieldMarshalText const OpStructFieldMarshalTextPtr const OpStructFieldNumber const OpStructFieldNumberPtr const OpStructFieldNumberPtrString const OpStructFieldNumberString const OpStructFieldOmitEmpty const OpStructFieldOmitEmptyArray const OpStructFieldOmitEmptyArrayPtr const OpStructFieldOmitEmptyBool const OpStructFieldOmitEmptyBoolPtr const OpStructFieldOmitEmptyBoolPtrString const OpStructFieldOmitEmptyBoolString const OpStructFieldOmitEmptyBytes const OpStructFieldOmitEmptyBytesPtr const OpStructFieldOmitEmptyFloat32 const OpStructFieldOmitEmptyFloat32Ptr const OpStructFieldOmitEmptyFloat32PtrString const OpStructFieldOmitEmptyFloat32String const OpStructFieldOmitEmptyFloat64 const OpStructFieldOmitEmptyFloat64Ptr const OpStructFieldOmitEmptyFloat64PtrString const OpStructFieldOmitEmptyFloat64String const OpStructFieldOmitEmptyInt const OpStructFieldOmitEmptyInterfacePtr const OpStructFieldOmitEmptyIntPtr const OpStructFieldOmitEmptyIntPtrString const OpStructFieldOmitEmptyIntString const OpStructFieldOmitEmptyMap const OpStructFieldOmitEmptyMapPtr const OpStructFieldOmitEmptyMarshalJSON const OpStructFieldOmitEmptyMarshalJSONPtr const OpStructFieldOmitEmptyMarshalText const OpStructFieldOmitEmptyMarshalTextPtr const OpStructFieldOmitEmptyNumber const OpStructFieldOmitEmptyNumberPtr const OpStructFieldOmitEmptyNumberPtrString const OpStructFieldOmitEmptyNumberString const OpStructFieldOmitEmptySlice const OpStructFieldOmitEmptySlicePtr const OpStructFieldOmitEmptyString const OpStructFieldOmitEmptyStringPtr const OpStructFieldOmitEmptyStringPtrString const OpStructFieldOmitEmptyStringString const OpStructFieldOmitEmptyStruct const OpStructFieldOmitEmptyUint const OpStructFieldOmitEmptyUintPtr const OpStructFieldOmitEmptyUintPtrString const OpStructFieldOmitEmptyUintString const OpStructFieldSlice const OpStructFieldSlicePtr const OpStructFieldString const OpStructFieldStringPtr const OpStructFieldStringPtrString const OpStructFieldStringString const OpStructFieldStruct const OpStructFieldUint const OpStructFieldUintPtr const OpStructFieldUintPtrString const OpStructFieldUintString const OpStructHead const OpStructHeadArray const OpStructHeadArrayPtr const OpStructHeadBool const OpStructHeadBoolPtr const OpStructHeadBoolPtrString const OpStructHeadBoolString const OpStructHeadBytes const OpStructHeadBytesPtr const OpStructHeadFloat32 const OpStructHeadFloat32Ptr const OpStructHeadFloat32PtrString const OpStructHeadFloat32String const OpStructHeadFloat64 const OpStructHeadFloat64Ptr const OpStructHeadFloat64PtrString const OpStructHeadFloat64String const OpStructHeadInt const OpStructHeadInterfacePtr const OpStructHeadIntPtr const OpStructHeadIntPtrString const OpStructHeadIntString const OpStructHeadMap const OpStructHeadMapPtr const OpStructHeadMarshalJSON const OpStructHeadMarshalJSONPtr const OpStructHeadMarshalText const OpStructHeadMarshalTextPtr const OpStructHeadNumber const OpStructHeadNumberPtr const OpStructHeadNumberPtrString const OpStructHeadNumberString const OpStructHeadOmitEmpty const OpStructHeadOmitEmptyArray const OpStructHeadOmitEmptyArrayPtr const OpStructHeadOmitEmptyBool const OpStructHeadOmitEmptyBoolPtr const OpStructHeadOmitEmptyBoolPtrString const OpStructHeadOmitEmptyBoolString const OpStructHeadOmitEmptyBytes const OpStructHeadOmitEmptyBytesPtr const OpStructHeadOmitEmptyFloat32 const OpStructHeadOmitEmptyFloat32Ptr const OpStructHeadOmitEmptyFloat32PtrString const OpStructHeadOmitEmptyFloat32String const OpStructHeadOmitEmptyFloat64 const OpStructHeadOmitEmptyFloat64Ptr const OpStructHeadOmitEmptyFloat64PtrString const OpStructHeadOmitEmptyFloat64String const OpStructHeadOmitEmptyInt const OpStructHeadOmitEmptyInterfacePtr const OpStructHeadOmitEmptyIntPtr const OpStructHeadOmitEmptyIntPtrString const OpStructHeadOmitEmptyIntString const OpStructHeadOmitEmptyMap const OpStructHeadOmitEmptyMapPtr const OpStructHeadOmitEmptyMarshalJSON const OpStructHeadOmitEmptyMarshalJSONPtr const OpStructHeadOmitEmptyMarshalText const OpStructHeadOmitEmptyMarshalTextPtr const OpStructHeadOmitEmptyNumber const OpStructHeadOmitEmptyNumberPtr const OpStructHeadOmitEmptyNumberPtrString const OpStructHeadOmitEmptyNumberString const OpStructHeadOmitEmptySlice const OpStructHeadOmitEmptySlicePtr const OpStructHeadOmitEmptyString const OpStructHeadOmitEmptyStringPtr const OpStructHeadOmitEmptyStringPtrString const OpStructHeadOmitEmptyStringString const OpStructHeadOmitEmptyStruct const OpStructHeadOmitEmptyUint const OpStructHeadOmitEmptyUintPtr const OpStructHeadOmitEmptyUintPtrString const OpStructHeadOmitEmptyUintString const OpStructHeadSlice const OpStructHeadSlicePtr const OpStructHeadString const OpStructHeadStringPtr const OpStructHeadStringPtrString const OpStructHeadStringString const OpStructHeadStruct const OpStructHeadUint const OpStructHeadUintPtr const OpStructHeadUintPtrString const OpStructHeadUintString const OpStructPtrHead const OpStructPtrHeadArray const OpStructPtrHeadArrayPtr const OpStructPtrHeadBool const OpStructPtrHeadBoolPtr const OpStructPtrHeadBoolPtrString const OpStructPtrHeadBoolString const OpStructPtrHeadBytes const OpStructPtrHeadBytesPtr const OpStructPtrHeadFloat32 const OpStructPtrHeadFloat32Ptr const OpStructPtrHeadFloat32PtrString const OpStructPtrHeadFloat32String const OpStructPtrHeadFloat64 const OpStructPtrHeadFloat64Ptr const OpStructPtrHeadFloat64PtrString const OpStructPtrHeadFloat64String const OpStructPtrHeadInt const OpStructPtrHeadInterfacePtr const OpStructPtrHeadIntPtr const OpStructPtrHeadIntPtrString const OpStructPtrHeadIntString const OpStructPtrHeadMap const OpStructPtrHeadMapPtr const OpStructPtrHeadMarshalJSON const OpStructPtrHeadMarshalJSONPtr const OpStructPtrHeadMarshalText const OpStructPtrHeadMarshalTextPtr const OpStructPtrHeadNumber const OpStructPtrHeadNumberPtr const OpStructPtrHeadNumberPtrString const OpStructPtrHeadNumberString const OpStructPtrHeadOmitEmpty const OpStructPtrHeadOmitEmptyArray const OpStructPtrHeadOmitEmptyArrayPtr const OpStructPtrHeadOmitEmptyBool const OpStructPtrHeadOmitEmptyBoolPtr const OpStructPtrHeadOmitEmptyBoolPtrString const OpStructPtrHeadOmitEmptyBoolString const OpStructPtrHeadOmitEmptyBytes const OpStructPtrHeadOmitEmptyBytesPtr const OpStructPtrHeadOmitEmptyFloat32 const OpStructPtrHeadOmitEmptyFloat32Ptr const OpStructPtrHeadOmitEmptyFloat32PtrString const OpStructPtrHeadOmitEmptyFloat32String const OpStructPtrHeadOmitEmptyFloat64 const OpStructPtrHeadOmitEmptyFloat64Ptr const OpStructPtrHeadOmitEmptyFloat64PtrString const OpStructPtrHeadOmitEmptyFloat64String const OpStructPtrHeadOmitEmptyInt const OpStructPtrHeadOmitEmptyInterfacePtr const OpStructPtrHeadOmitEmptyIntPtr const OpStructPtrHeadOmitEmptyIntPtrString const OpStructPtrHeadOmitEmptyIntString const OpStructPtrHeadOmitEmptyMap const OpStructPtrHeadOmitEmptyMapPtr const OpStructPtrHeadOmitEmptyMarshalJSON const OpStructPtrHeadOmitEmptyMarshalJSONPtr const OpStructPtrHeadOmitEmptyMarshalText const OpStructPtrHeadOmitEmptyMarshalTextPtr const OpStructPtrHeadOmitEmptyNumber const OpStructPtrHeadOmitEmptyNumberPtr const OpStructPtrHeadOmitEmptyNumberPtrString const OpStructPtrHeadOmitEmptyNumberString const OpStructPtrHeadOmitEmptySlice const OpStructPtrHeadOmitEmptySlicePtr const OpStructPtrHeadOmitEmptyString const OpStructPtrHeadOmitEmptyStringPtr const OpStructPtrHeadOmitEmptyStringPtrString const OpStructPtrHeadOmitEmptyStringString const OpStructPtrHeadOmitEmptyStruct const OpStructPtrHeadOmitEmptyUint const OpStructPtrHeadOmitEmptyUintPtr const OpStructPtrHeadOmitEmptyUintPtrString const OpStructPtrHeadOmitEmptyUintString const OpStructPtrHeadSlice const OpStructPtrHeadSlicePtr const OpStructPtrHeadString const OpStructPtrHeadStringPtr const OpStructPtrHeadStringPtrString const OpStructPtrHeadStringString const OpStructPtrHeadStruct const OpStructPtrHeadUint const OpStructPtrHeadUintPtr const OpStructPtrHeadUintPtrString const OpStructPtrHeadUintString const OpUint const OpUintPtr const OpUintPtrString const OpUintString
(*PtrCode) Filter(query *FieldQuery) Code (*PtrCode) Kind() CodeKind (*PtrCode) ToAnonymousOpcode(ctx *compileContext) Opcodes (*PtrCode) ToOpcode(ctx *compileContext) Opcodes *PtrCode : AnonymousCode *PtrCode : Code
BaseIndent uint32 Buf []byte Context context.Context IndentStr []byte KeepRefs []unsafe.Pointer MarshalBuf []byte Option *Option Prefix []byte Ptrs []uintptr SeenPtr []uintptr (*RuntimeContext) Init(p uintptr, codelen int) (*RuntimeContext) Ptr() uintptr func TakeRuntimeContext() *RuntimeContext func AppendBool(_ *RuntimeContext, b []byte, v bool) []byte func AppendByteSlice(_ *RuntimeContext, b []byte, src []byte) []byte func AppendComma(_ *RuntimeContext, b []byte) []byte func AppendCommaIndent(_ *RuntimeContext, b []byte) []byte func AppendFloat32(_ *RuntimeContext, b []byte, v float32) []byte func AppendFloat64(_ *RuntimeContext, b []byte, v float64) []byte func AppendIndent(ctx *RuntimeContext, b []byte, indent uint32) []byte func AppendInt(_ *RuntimeContext, out []byte, p uintptr, code *Opcode) []byte func AppendMarshalJSON(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendMarshalJSONIndent(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendMarshalText(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendMarshalTextIndent(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error) func AppendNull(_ *RuntimeContext, b []byte) []byte func AppendNumber(_ *RuntimeContext, b []byte, n json.Number) ([]byte, error) func AppendString(ctx *RuntimeContext, buf []byte, s string) []byte func AppendStructEnd(_ *RuntimeContext, b []byte) []byte func AppendStructEndIndent(ctx *RuntimeContext, code *Opcode, b []byte) []byte func AppendUint(_ *RuntimeContext, out []byte, p uintptr, code *Opcode) []byte func CompileToGetCodeSet(ctx *RuntimeContext, typeptr uintptr) (*OpcodeSet, error) func ReleaseRuntimeContext(ctx *RuntimeContext) func github.com/goccy/go-json/internal/encoder/vm.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color_indent.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_color_indent.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_indent.DebugRun(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error) func github.com/goccy/go-json/internal/encoder/vm_indent.Run(ctx *RuntimeContext, b []byte, codeSet *OpcodeSet) ([]byte, error)
(*SliceCode) Filter(_ *FieldQuery) Code (*SliceCode) Kind() CodeKind (*SliceCode) ToOpcode(ctx *compileContext) Opcodes *SliceCode : Code
(*StringCode) Filter(_ *FieldQuery) Code (*StringCode) Kind() CodeKind (*StringCode) ToOpcode(ctx *compileContext) Opcodes *StringCode : Code
(*StructCode) Filter(query *FieldQuery) Code (*StructCode) Kind() CodeKind (*StructCode) ToAnonymousOpcode(ctx *compileContext) Opcodes (*StructCode) ToOpcode(ctx *compileContext) Opcodes *StructCode : AnonymousCode *StructCode : Code
(*StructFieldCode) ToAnonymousOpcode(ctx *compileContext, isFirstField, isEndField bool) Opcodes (*StructFieldCode) ToOpcode(ctx *compileContext, isFirstField, isEndField bool) Opcodes
(*UintCode) Filter(_ *FieldQuery) Code (*UintCode) Kind() CodeKind (*UintCode) ToOpcode(ctx *compileContext) Opcodes *UintCode : Code
Package-Level Functions (total 52)
func AppendBool(_ *RuntimeContext, b []byte, v bool) []byte
func AppendByteSlice(_ *RuntimeContext, b []byte, src []byte) []byte
func AppendIndent(ctx *RuntimeContext, b []byte, indent uint32) []byte
func AppendInt(_ *RuntimeContext, out []byte, p uintptr, code *Opcode) []byte
func AppendMarshalJSON(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error)
func AppendMarshalJSONIndent(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error)
func AppendMarshalText(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error)
func AppendMarshalTextIndent(ctx *RuntimeContext, code *Opcode, b []byte, v interface{}) ([]byte, error)
func AppendString(ctx *RuntimeContext, buf []byte, s string) []byte
func AppendUint(_ *RuntimeContext, out []byte, p uintptr, code *Opcode) []byte
func Compact(buf *bytes.Buffer, src []byte, escape bool) error
func Indent(buf *bytes.Buffer, src []byte, prefix, indentStr string) error
func IsNilForMarshaler(v interface{}) bool
func Load(base uintptr, idx uintptr) uintptr
func LoadNPtr(base uintptr, idx uintptr, ptrNum int) uintptr
func MapIterInit(mapType *runtime.Type, m unsafe.Pointer, it *mapIter)
func MapIterNext(it *mapIter)
func NewMapContext(mapLen int, unorderedMap bool) *MapContext
func PtrToInterface(code *Opcode, p uintptr) interface{}
func PtrToNPtr(p uintptr, ptrNum int) uintptr
func Store(base uintptr, idx uintptr, p uintptr)
func ToEndCode(code *Opcode) *Opcode
Package-Level Variables (total 2)
var Marshal (interface{}) ([]byte, error)
var Unmarshal ([]byte, interface{}) error
Package-Level Constants (total 446)
const CodeMapEnd CodeType = 8
const CodeMapKey CodeType = 6
const CodeOp CodeType = 0
const OpArray OpType = 22
const OpArrayElem OpType = 5
const OpArrayEnd OpType = 6
const OpArrayPtr OpType = 43
const OpBool OpType = 18
const OpBoolPtr OpType = 39
const OpBoolString OpType = 32
const OpBytes OpType = 20
const OpBytesPtr OpType = 41
const OpEnd OpType = 0
const OpFloat32 OpType = 16
const OpFloat32Ptr OpType = 37
const OpFloat64 OpType = 17
const OpFloat64Ptr OpType = 38
const OpInt OpType = 14
const OpInterface OpType = 1
const OpIntPtr OpType = 35
const OpIntString OpType = 28
const OpMap OpType = 23
const OpMapEnd OpType = 9
const OpMapKey OpType = 7
const OpMapPtr OpType = 44
const OpMapValue OpType = 8
const OpMarshalJSON OpType = 26
const OpMarshalText OpType = 27
const OpNumber OpType = 21
const OpNumberPtr OpType = 42
const OpPtr OpType = 2
const OpRecursive OpType = 10
const OpSlice OpType = 24
const OpSliceElem OpType = 3
const OpSliceEnd OpType = 4
const OpSlicePtr OpType = 45
const OpString OpType = 19
const OpStringPtr OpType = 40
const OpStruct OpType = 25
const OpStructEnd OpType = 398
const OpStructEndBool OpType = 246
const OpStructEndInt OpType = 230
const OpStructEndMap OpType = 266
const OpStructEndUint OpType = 234
const OpStructField OpType = 396
const OpStructHead OpType = 224
const OpStructPtrHead OpType = 226
const OpUint OpType = 15
const OpUintPtr OpType = 36
const OpUintString OpType = 29