Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArraySerialiser ¶
type ArraySerialiser struct {
// contains filtered or unexported fields
}
ArraySerialiser is a JSON serialiser which wraps serialised objects into an array. Under the hood it uses a combination of json.Encoder and a bytes.Buffer.
func NewArraySerialiser ¶
func NewArraySerialiser(bufSize int) (*ArraySerialiser, error)
NewArraySerialiser returns a new ArraySerialiser with specified buffer size.
func (*ArraySerialiser) Finalise ¶
func (a *ArraySerialiser) Finalise() ([]byte, error)
Finalise finalises the serialised data by closing the array and returning the resulting byte representation of the data.
func (*ArraySerialiser) Write ¶
func (a *ArraySerialiser) Write(val interface{}) error
Click to show internal directories.
Click to hide internal directories.