Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

Using this packages we can access dictionary values using dot operator

Project description

access_dict_by_dot

Using this package, we can access the items in a dictionary using dot operator instead of writiting dict_name["key"].

for example

from access_dict_by_dot import AccessDictByDot

dictionary = {
    'key1':'value1',
    'key2':'value2',
    'key3':{
                'subkey1':'subvalue1',
                'subkey2':'subvalue2'
            }
}


d = AccessDictByDot.load(dictionary)
print(d.key1)
print(d.key3.subkey1)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for access-dict-by-dot, version 0.0.4
Filename, size File type Python version Upload date Hashes
Filename, size access_dict_by_dot-0.0.4.tar.gz (1.8 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page