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.16.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

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

filesystem_dict-0.1.16-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file filesystem_dict-0.1.16.tar.gz.

File metadata

  • Download URL: filesystem_dict-0.1.16.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for filesystem_dict-0.1.16.tar.gz
Algorithm Hash digest
SHA256 cadb3d1700819af48a4189c68d6127a2ca8c059be772de69e1e0d83da2944440
MD5 e8299de046dccf48fe5f711f0b0158a3
BLAKE2b-256 2bc54b2ac8893a728cc7db10236c5f9ae22b26f084337b3305603cd6073f4f3e

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for filesystem_dict-0.1.16-py3-none-any.whl
Algorithm Hash digest
SHA256 d235d2359dcd5fd9348ee15f2d3d0292ba583a0526d4501d413503a21cc133e8
MD5 39a87414448bcb58070133abaa4fa182
BLAKE2b-256 6ab6532688cbba03b4d65f166ba7190373d5612267610dc2221fd90fffdb9499

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