type encoding/json/jsontext.Encoder
63 uses
encoding/json/jsontext (current package)
encode.go#L48: type Encoder struct {
encode.go#L91: func NewEncoder(w io.Writer, opts ...Options) *Encoder {
encode.go#L92: e := new(Encoder)
encode.go#L101: func (e *Encoder) Reset(w io.Writer, opts ...Options) {
encode.go#L140: func (e *Encoder) Options() Options {
encode.go#L344: func (e *Encoder) WriteToken(t Token) error {
encode.go#L524: func (e *Encoder) WriteValue(v Value) error {
encode.go#L900: func (e *Encoder) OutputOffset() int64 {
encode.go#L919: func (e *Encoder) AvailableBuffer() []byte {
encode.go#L956: func (e *Encoder) StackDepth() int {
encode.go#L973: func (e *Encoder) StackIndex(i int) (Kind, int64) {
encode.go#L986: func (e *Encoder) StackPointer() Pointer {
export.go#L55: func (export) Encoder(e *Encoder) *encoderState { return &e.s }
export.go#L60: func (export) GetBufferedEncoder(o ...Options) *Encoder {
export.go#L63: func (export) PutBufferedEncoder(e *Encoder) {
export.go#L67: func (export) GetStreamingEncoder(w io.Writer, o ...Options) *Encoder {
export.go#L70: func (export) PutStreamingEncoder(e *Encoder) {
pools.go#L23: bufferedEncoderPool = &sync.Pool{New: func() any { return new(Encoder) }}
pools.go#L29: streamingEncoderPool = &sync.Pool{New: func() any { return new(Encoder) }}
pools.go#L33: bytesBufferEncoderPool = &sync.Pool{New: func() any { return new(Encoder) }}
pools.go#L44: func getBufferedEncoder(opts ...Options) *Encoder {
pools.go#L45: e := bufferedEncoderPool.Get().(*Encoder)
pools.go#L56: func putBufferedEncoder(e *Encoder) {
pools.go#L90: func getStreamingEncoder(w io.Writer, opts ...Options) *Encoder {
pools.go#L92: e := bytesBufferEncoderPool.Get().(*Encoder)
pools.go#L96: e := streamingEncoderPool.Get().(*Encoder)
pools.go#L101: func putStreamingEncoder(e *Encoder) {
encoding/json
v2_decode.go#L212: func (n Number) MarshalJSONTo(enc *jsontext.Encoder) error {
encoding/json/v2
arshal.go#L197: func MarshalEncode(out *jsontext.Encoder, in any, opts ...Options) (err error) {
arshal.go#L227: func marshalEncode(out *jsontext.Encoder, in any, mo *jsonopts.Struct) (err error) {
arshal.go#L516: marshaler = func(*jsontext.Encoder, addressableValue, *jsonopts.Struct) error
arshal_any.go#L32: func marshalValueAny(enc *jsontext.Encoder, val any, mo *jsonopts.Struct) error {
arshal_any.go#L107: func marshalObjectAny(enc *jsontext.Encoder, obj map[string]any, mo *jsonopts.Struct) error {
arshal_any.go#L223: func marshalArrayAny(enc *jsontext.Encoder, arr []any, mo *jsonopts.Struct) error {
arshal_default.go#L128: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L213: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L335: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L470: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L569: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L659: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L797: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L1122: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L1477: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L1625: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L1727: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L1811: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_default.go#L1975: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_embedded.go#L40: func marshalEmbeddedFallbackAll(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct, f *structField, insertUnquotedName func([]byte) bool) error {
arshal_funcs.go#L71: type typedMarshalers = typedArshalers[jsontext.Encoder]
arshal_funcs.go#L90: type typedMarshaler = typedArshaler[jsontext.Encoder]
arshal_funcs.go#L173: fnc: func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_funcs.go#L209: func MarshalToFunc[T any](fn func(*jsontext.Encoder, T) error) *Marshalers {
arshal_funcs.go#L214: fnc: func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_methods.go#L100: MarshalJSONTo(*jsontext.Encoder) error
arshal_methods.go#L179: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_methods.go#L207: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) (err error) {
arshal_methods.go#L232: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_methods.go#L264: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_time.go#L46: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) error {
arshal_time.go#L136: fncs.marshal = func(enc *jsontext.Encoder, va addressableValue, mo *jsonopts.Struct) (err error) {
errors.go#L116: case *jsontext.Encoder:
errors.go#L126: func newMarshalErrorBefore(e *jsontext.Encoder, t reflect.Type, err error) error {
errors.go#L230: case *jsontext.Encoder: