Documentation ¶
Overview ¶
Package bfr provides a common interface for buffered writers and a bytes.Buffer pool.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Grow ¶
Grow grows the buffer by n if it implements a Grow(int) method. Both bytes.Buffer and strings.Builder implement that method.
Types ¶
type B ¶
type B interface { Write([]byte) (int, error) WriteByte(byte) error WriteRune(rune) (int, error) WriteString(string) (int, error) }
B is the common interface of bytes.Buffer, strings.Builder and bufio.Writer.
type Ctx ¶
Ctx is serialization context with output configuration flags
func (*Ctx) Quote ¶
Quote writes v as quoted string to the buffer or returns an error. The quote used depends on the json context flag.
Click to show internal directories.
Click to hide internal directories.