Skip to content

singlemusic/go-ordered-json

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JSON object parsing with preserving keys order

coverage

Refers

  1. JSON and Go https://blog.golang.org/json-and-go
  2. Go-Ordered-JSON https://github.com/virtuald/go-ordered-json from this thread Preserving key order in encoding/json and the Abandoned 7930: encoding/json: Optionally preserve the key order of JSON objects
  3. Python OrderedDict https://github.com/python/cpython/blob/2.7/Lib/collections.py#L38 the Python's OrderedDict uses a double linked list internally, maintain a consistent public interface with dict

Disclaimer:

same as Go's default map, this OrderedMap is not safe for concurrent use, if need atomic access, may use a sync.Mutex to synchronize.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages