Nested Dict Update With operation like insert , deleter , updater ,search
Project description
Dict Updater
It used to update any nested dict and list object . Also provide the option to update nested dictionary within the list by searching mechanism .
Feature Offer :
- Update the dictionary object .
- Delete nested dictionary value .
- Append nested list object .
How to Install the library
pip install dictupdate
Example
Updating simple dictionary object
from dictupdate import DictUpdater
# source to update
source = {
"a" : {
"b": "value_need_to_update"
}
}
# target to update
target = {
"a":{
"b": "existing value updated",
"c": "new value added"
}
}
dict_update = DictUpdater.update(
data=source,
update_value=target
)
print(dict_update)
Output :
{'a': {'b': 'existing value updated', 'c': 'new value added'}}
Updating Recursive
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
dictupdate-0.0.3.tar.gz
(5.8 kB
view hashes)
Built Distribution
Close
Hashes for dictupdate-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ed71ff74e8883551b0fdd1889e9ef0c35a1876762ea37ad641bcac1092e1fb67 |
|
MD5 | 191dd998370212bc62be9ff9c10357ea |
|
BLAKE2b-256 | 9b68cff9aff92a3e5c360d42cfc316e5b74f3c021eba53c462bae548c7f64370 |