Skip to main content

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.

Source Distribution

access_dict_by_dot-0.0.4.tar.gz (1.8 kB view details)

Uploaded Source

File details

Details for the file access_dict_by_dot-0.0.4.tar.gz.

File metadata

  • Download URL: access_dict_by_dot-0.0.4.tar.gz
  • Upload date:
  • Size: 1.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.6.5

File hashes

Hashes for access_dict_by_dot-0.0.4.tar.gz
Algorithm Hash digest
SHA256 54446f3a73df3d881af3395cdc8996f7ad6d4fb8f81ffd69834f0115480c05a9
MD5 7ca4d2a501605253ee1028ad8b8e366d
BLAKE2b-256 45b57308c57d597cca4b2763a131f116aadb5199311575d4fc2968233d006b34

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page