Skip to content

nagasuga/jsonh

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Develop: Build Status

Master: Build Status

JSONH

JSON Homogeneous Collections Compressor

What is JSONH

JSONH is one of the most performant, yet safe, cross programming language, way to pack and unpack generic homogenous collections.

This version is a wrapper around the JSONH that takes any object, not just a list of dictionaries, to pack to a JSONH formatted JSON object.

Pro

  • Convenience - Any object that can be dumped to JSON to be in JSONH format.
  • Size - Nested list of JSONH packable objects will all be converted into JSONH format.

Con

  • Speed - Requires to traverse the entire obj to recursively pack every data.

Installation

pip install git+https://github.com/nagasuga/jsonh

Usage

import jsonh

data = {
    'status': 'success',
    'data': [
        {
          'name': 'John',
          'age': 12,
        },
        {
          'name': 'Steve',
          'age': 73,
        },
        {
          'name': 'Mickey',
          'age': 39,
        },
    ],
}

dumped = jsonh.dumps(data)
loaded = jsonh.loads(dumped)

About

JSON Homogeneous Collections Compressor

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages