Versions in this module Expand all Collapse all v1 v1.3.6 Aug 10, 2022 Changes in this version + func Encode(val interface{}, opts Options) ([]byte, error) + func EncodeIndented(val interface{}, prefix string, indent string, opts Options) ([]byte, error) + func EncodeInto(buf *[]byte, val interface{}, opts Options) error + func HTMLEscape(dest []byte, src []byte) []byte + func Pretouch(vt reflect.Type, opts ...option.CompileOption) error + func Quote(s string) string + func Valid(data []byte) (ok bool, start int) + type Encoder struct + Opts Options + func (enc *Encoder) SetIndent(prefix, indent string) + func (self *Encoder) Encode(v interface{}) ([]byte, error) + func (self *Encoder) SetCompactMarshaler(f bool) + func (self *Encoder) SetEscapeHTML(f bool) + func (self *Encoder) SetNoQuoteTextMarshaler(f bool) + func (self *Encoder) SortKeys() *Encoder + type Options uint64 + const CompactMarshaler + const CompatibleWithStd + const EscapeHTML + const NoNullSliceOrMap + const NoQuoteTextMarshaler + const SortMapKeys + type StreamEncoder struct + func NewStreamEncoder(w io.Writer) *StreamEncoder + func (enc *StreamEncoder) Encode(val interface{}) (err error)