Name | jsonUts JSON |
Version |
1.0.3
JSON |
| download |
home_page | None |
Summary | Json package |
upload_time | 2024-05-27 12:36:13 |
maintainer | None |
docs_url | None |
author | Melque Lima |
requires_python | None |
license | MIT |
keywords |
jsonuts
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Json Uts
#
### Installation
```sh
pip install jsonUts
```
## GitHub
https://github.com/ZdekPyPi/JsonUts
### Usage
#
#### Json sample
```json
my_json = {
"person":{
"name":"json uts",
"age": 30
},
"my cars":[
{"pattern":"Ferrari","year":2015},
{"pattern":"Lamborghini","year":2018}
],
"job":"Software developer",
"UpperCase":123,
"with space":"lets go!"
}
```
#### simple transform
```py
from jsonUts import jsonToObj
jsonO = jsonToObj(my_json)
#jsonO = jsonToObj(my_json,toLower=True) # to convert all keys in lower case.
#jsonO = jsonToObj(my_json,trim_keys=True) # remove white spaces from the start and end
print(jsonO.person.name)
print(jsonO.job)
print(jsonO.with_space)
print(jsonO.my_cars[0].pattern)
```
#### Reverse
```py
#After creating you object (jsonO), you can use it
json_again = jsonO.toJson()
json_again_original = jsonO.toJson(original_keys=True) # if you want your original key names back
```
```py
'2022-05-25'
```
Change Log
==========
0.0.1 (2024-04-19)
------------------
- First Release
Raw data
{
"_id": null,
"home_page": null,
"name": "jsonUts",
"maintainer": null,
"docs_url": null,
"requires_python": null,
"maintainer_email": null,
"keywords": "jsonUts",
"author": "Melque Lima",
"author_email": "melque_ex@yahoo.com.br",
"download_url": "https://files.pythonhosted.org/packages/1d/33/73d92730b849dcb266d31f8713f8a43b81f762aa47a55e4dfebbd87704d5/jsonUts-1.0.3.tar.gz",
"platform": null,
"description": "# Json Uts\r\n#\r\n### Installation\r\n\r\n```sh\r\npip install jsonUts\r\n```\r\n\r\n## GitHub\r\nhttps://github.com/ZdekPyPi/JsonUts\r\n\r\n\r\n### Usage\r\n#\r\n#### Json sample\r\n```json\r\nmy_json = {\r\n \"person\":{\r\n \"name\":\"json uts\",\r\n \"age\": 30\r\n },\r\n \"my cars\":[\r\n {\"pattern\":\"Ferrari\",\"year\":2015},\r\n {\"pattern\":\"Lamborghini\",\"year\":2018}\r\n ],\r\n \"job\":\"Software developer\",\r\n \"UpperCase\":123,\r\n \"with space\":\"lets go!\"\r\n}\r\n```\r\n#### simple transform\r\n```py\r\nfrom jsonUts import jsonToObj\r\n\r\njsonO = jsonToObj(my_json)\r\n#jsonO = jsonToObj(my_json,toLower=True) # to convert all keys in lower case.\r\n#jsonO = jsonToObj(my_json,trim_keys=True) # remove white spaces from the start and end\r\n\r\nprint(jsonO.person.name) \r\nprint(jsonO.job) \r\nprint(jsonO.with_space)\r\nprint(jsonO.my_cars[0].pattern)\r\n```\r\n\r\n#### Reverse\r\n```py\r\n#After creating you object (jsonO), you can use it\r\n\r\njson_again = jsonO.toJson()\r\njson_again_original = jsonO.toJson(original_keys=True) # if you want your original key names back\r\n\r\n```\r\n```py\r\n'2022-05-25'\r\n```\r\n\r\n\r\nChange Log\r\n==========\r\n\r\n0.0.1 (2024-04-19)\r\n------------------\r\n- First Release\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Json package",
"version": "1.0.3",
"project_urls": null,
"split_keywords": [
"jsonuts"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "1d3373d92730b849dcb266d31f8713f8a43b81f762aa47a55e4dfebbd87704d5",
"md5": "e99a9bec85c818cb06de860f5e9732b2",
"sha256": "786e766bb6cfe5a2a5a6cd2db4ec474da09e1e3f2215440885da9c4a9e8335c3"
},
"downloads": -1,
"filename": "jsonUts-1.0.3.tar.gz",
"has_sig": false,
"md5_digest": "e99a9bec85c818cb06de860f5e9732b2",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 3866,
"upload_time": "2024-05-27T12:36:13",
"upload_time_iso_8601": "2024-05-27T12:36:13.249013Z",
"url": "https://files.pythonhosted.org/packages/1d/33/73d92730b849dcb266d31f8713f8a43b81f762aa47a55e4dfebbd87704d5/jsonUts-1.0.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-27 12:36:13",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "jsonuts"
}