Skip to main content

Module for parsing and writing DCMI structured value strings

Project description

DCSV

Python module for serializing structured data to and from the Dublin Core Metadata Initiative DCSV format (Cox & Iannella, 2006).

Installation

$ pip install dscv

Usage

>>> import dcsv

>>> dcsv.dumps({'foo': 2, 'bar': 3})
'foo=2; bar=3'

>>> dcsv.loads('pi=3.14')
{'pi': 3.14}

List of dictionaries are also supported using special hierarchical keys:

>>> dcsv.dumps([{'foo': 'bar'}, {'foo': 'baz'}])
'#1.foo=bar; #2.foo=baz'

>>> dcsv.loads('#1.foo=bar; #2.foo=baz')
[{'foo': 'bar'}, {'foo': 'baz'}]

References

Cox, S. and Iannella, R. (2006) DCMI DCSV. Available at: https://www.dublincore.org/specifications/dublin-core/dcmi-dcsv/.

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

dcsv-1.1.1.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

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

dcsv-1.1.1-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file dcsv-1.1.1.tar.gz.

File metadata

  • Download URL: dcsv-1.1.1.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for dcsv-1.1.1.tar.gz
Algorithm Hash digest
SHA256 836250a90e77604e301e9599ae576a9aae19c8e88f11cc05bc84f853d5864d7a
MD5 3c3a362e3f8d59439a79eff6d0426e48
BLAKE2b-256 5f594202972895b7067fdf373e146595941cca85615bf57da2304b0ee72b3c41

See more details on using hashes here.

File details

Details for the file dcsv-1.1.1-py3-none-any.whl.

File metadata

  • Download URL: dcsv-1.1.1-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for dcsv-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9f6ac9d0ec7b9496dadce9b1f3aaf33636e3c2ba328eb451e94f3a2f9442b29d
MD5 2593807baf77306d9419a28a5fcb3484
BLAKE2b-256 3183e050b4ea02cb58f172a1e983c6b07dbd79750335897dbe52ac754d483523

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