Skip to content

gpwork4u/json_tools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

json_tools

A tool for analysis json content

install

pip install json-tools-python

How to use

import json_tools
test_data = {
    'a':{
        'b':{
            'c':'123',
            'd':{
                'c':123,
            },
            'e':[{'a':1}, {'b':2}, {'c':3}],
            'f':[
                {'a':
                    {'c':1}
                },
                {'b':
                    {'c':2}
                }
            ]
        }
    }
}
for ret in json_tools.search(test_data, 'c'):
    print(ret)

result:

['a', 'b', 'c']
['a', 'b', 'd', 'c']
['a', 'b', 'e', 2, 'c']
['a', 'b', 'f', 0, 'a', 'c']
['a', 'b', 'f', 1, 'b', 'c']

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages