Skip to main content

Dictionary like access to the filesystem.

Project description

FSDict

Design principles

  1. Every key of a fsdict must be of type 'str' or 'FunctionType'.
  2. A fsdict may not be part of a list.
  3. A fsdict may contain other fsdicts.
  4. Dictionaries in python are passed by reference; so are fsdicts. By default an fsdict is always passed by refernece. That is, its values are not copied but the fsdict is symlinked to the new position.

Internals

Keys of type 'str' work just as normal dictionary keys. Keys of type 'FunctionType' are used as filters for the keys of an fsdict. So

dictionary[lambda key: "foo" in key]

would return a generator which yields the values for keys which contain the string 'foo'.

Possible value types and how they are handled:

  • fsdict - a directory
  • 'bytes' type - written to file as is
  • any other python object (except for 'bytes') - pickled

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

filesystem-dict-0.1.15.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

filesystem_dict-0.1.15-py3-none-any.whl (4.3 kB view details)

Uploaded Python 3

File details

Details for the file filesystem-dict-0.1.15.tar.gz.

File metadata

  • Download URL: filesystem-dict-0.1.15.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.3

File hashes

Hashes for filesystem-dict-0.1.15.tar.gz
Algorithm Hash digest
SHA256 4db822334bd038ba89a43b1a8d70be2a987264e8f1d6c626762f31f1193edcd4
MD5 e1497fca2f7d99eab84097c41a157682
BLAKE2b-256 fa278c9a96a3f12002d11d037485b387ae4fc18195fa98c746e7e9e0b2d606e2

See more details on using hashes here.

File details

Details for the file filesystem_dict-0.1.15-py3-none-any.whl.

File metadata

File hashes

Hashes for filesystem_dict-0.1.15-py3-none-any.whl
Algorithm Hash digest
SHA256 f0f1df19cffc307d90159c59ee2976fbc11c1f77ccc69a7ad0be8ebf26a76969
MD5 48b1231a2b5173ae5f3ccd45ae1b8e17
BLAKE2b-256 aa6523fcef670f75e1488913e2a79299908ff9b415597ec240b9e0ca63c48836

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