Skip to main content

Like dict, but easier

Project description

What is this?

A python package that provides an alternative to dict that is much easier for lazy people to use.

How do I use this?

pip install super_map

from super_map import Map, LazyDict

item = Map()

# no error
item["value"]["subvalue"] = True

# prints true
print(item.value.subvalue == item["value"]["subvalue"]) # prints true

# dont need .items()
for each_key, each_value in item:
    print(each_key)

for each_key in item[Map.Keys]:
    print(each_key)

for each_key in item[Map.Values]:
    print(each_key)

value = item.a.b.c.d.e
if not value:
    # this prints out
    print("item.a.b.c.d.e doesn't exist")

item_as_dict = item[Map.Dict]

item.f.g.h += 1
print('will print out 1:', item.f.g.h)

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

super_map-1.2.2.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

super_map-1.2.2-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file super_map-1.2.2.tar.gz.

File metadata

  • Download URL: super_map-1.2.2.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.6

File hashes

Hashes for super_map-1.2.2.tar.gz
Algorithm Hash digest
SHA256 b385a9d834036b48046da0e47296fdb15acd63b9d46a6694b9f0834ee9c16ec6
MD5 5bfe6df0f4c3d6bd3302d84eae29022c
BLAKE2b-256 312f4b1d90806502cf0ae4a1a886a266046b51a0eb24788af1f25227a4e1d1ad

See more details on using hashes here.

File details

Details for the file super_map-1.2.2-py3-none-any.whl.

File metadata

  • Download URL: super_map-1.2.2-py3-none-any.whl
  • Upload date:
  • Size: 6.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.6

File hashes

Hashes for super_map-1.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4b8ad3b1c273dbed03bd0367616de4809de2bf5f377cca5ff551e96f1bb9e3ef
MD5 20ad789f5ccfab623d808bf251b849be
BLAKE2b-256 d09cba87b285b7075e9127e8ad99b7a1ccf8312e08ddc52afc36ab9e86a4a9b0

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