Skip to main content

Lightweight namedtuple wrapper for attribute-style data access (a la JavaScript objects).

Project description

https://travis-ci.org/brennv/namedtupled.svg?branch=master https://img.shields.io/badge/python-2.7%2C%203.4%2C%203.5-blue.svg https://img.shields.io/codecov/c/github/brennv/namedtupled.svg

Source: https://github.com/brennv/namedtupled

Docs: https://namedtupled.readthedocs.io

namedtuples are immutable, performant and classy. namedtupled is a lightweight wrapper for recursively creating namedtuples from nested dicts, lists, json and yaml. Inspired by hangtwenty.

Installation

pip install namedtupled

Getting started

import namedtupled

data = {'binks': {'says': 'meow'}}
cat = namedtupled.map(data)

cat  # NT(binks=NT(says='meow'))

cat.binks.says  # 'meow'

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

namedtupled-0.3.3.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

namedtupled-0.3.3-py2.py3-none-any.whl (5.8 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file namedtupled-0.3.3.tar.gz.

File metadata

  • Download URL: namedtupled-0.3.3.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for namedtupled-0.3.3.tar.gz
Algorithm Hash digest
SHA256 79c793fae4c996ae8c988e502f3568e04e937ef315a9fdc957779f3029296985
MD5 d935c3f445d1c6790404b666793409c2
BLAKE2b-256 8837e12bab824e76dd597467a94462b9c55feec32a0465844cbeb826c956c942

See more details on using hashes here.

File details

Details for the file namedtupled-0.3.3-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for namedtupled-0.3.3-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 e168b155672987fc7ae367d8833120deb86ed6766da1442f68ca06617cd7b07a
MD5 735bf5f475934dbb66670dcf9f414db7
BLAKE2b-256 b9efddec4c396dd9902d54e385ba5a2a984df836f9efacc41f372998c59d1340

See more details on using hashes here.

Supported by

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