Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrUnsupportedOption unsupported option ErrUnsupportedOption = errors.New("unsupported option") )
Functions ¶
Types ¶
type Codec ¶
type Codec interface { NewCodec() Codec NewEncoder(w io.Writer) (Encoder, error) NewDecoder(r io.Reader) (Decoder, error) Encode(v interface{}) ([]byte, error) Decode(b []byte, v interface{}) error SetIndent(indent string) error SetMapString() error }
Codec interface.
type Option ¶
Option variadic function.
func WithIndent ¶
WithIndent indent output. Supported by JSON.
func WithMapString ¶
func WithMapString() Option
WithMapString convert map[interface{}]interface{} to map[string]interface{}. Suppored by YAML.
Click to show internal directories.
Click to hide internal directories.