Table Of Contents

Next topic

2.1.8.1.1. systemmetadata.parseDateString

This Page

2.1.8. systemmetadata

2.1.8.1. Module d1_client.systemmetadata

Implements a wrapper that makes it a bit simpler to pull values from an instance of SystemMetadata.

Created:

2010-01-11

Author:

Vieglais

Dependencies:
  • dateutil: useful python library for parsing dates, available from http://labix.org/python-dateutil or easy_install python-dateutil
  • minixsv: required for validation against schemas.
Example:
>>> target = "http://localhost:8000/mn"
>>> from d1_client import client
>>> cli = client.DataOneClient()
>>> objects = cli.listObjects(target=target,count=3)
>>> objects['data'][0]['pid']
u'02c3f67e-b2e1-4550-8fae-f6d90e9f15f6'
>>> sysm = cli.getSystemMetadata(objects['data'][0]['pid'], target=target)
>>> sysm.Checksum
'2e01e17467891f7c933dbaa00e1459d23db3fe4f'

Functions

parseDateString(timestr[, parserinfo])

Classes

SystemMetadata(xmldoc) Wrapper around a System Metadata entry. Provides convenience properties