original

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 3, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package original provides an example usage of unmarshalling JSON into a struct without using sync.Pool and allocating a new struct every time.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UnmarshalObject

func UnmarshalObject(jsonString string) (base.Object, error)

UnmarshalObject writes jsonString into a *bytes.Buffer allocated each time UnmarshalObject is called and unmarshals the buffer into a *base.Object. It then returns the dereferenced base.Object. The *base.Object used is also allocated each time UnmarshalObject is called.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL