A lightweight OAI client library for Python
Project description
Sickle
~~~~~~
Sickle is a lightweight OAI client library for Python.
Using Sickle
------------
>>> from sickle import Sickle
>>> client = Sickle('http://elis.da.ulcc.ac.uk/cgi/oai2')
>>> response = client.ListRecords(metadataPrefix='oai_dc')
Sickle provides different levels of abstraction for working with OAI
responses::
>>> response.xml
<Element {http://www.openarchives.org/OAI/2.0/}OAI-PMH at 0x10469a8c0>
>>> response.raw
u'<?xml version='1.0' encoding ...'
And a convenient way for iterating through all records of a repository:
>>> records = response.iter()
>>> records.next()
<Element {http://www.openarchives.org/OAI/2.0/}record at 0x1051b3b90>
~~~~~~
Sickle is a lightweight OAI client library for Python.
Using Sickle
------------
>>> from sickle import Sickle
>>> client = Sickle('http://elis.da.ulcc.ac.uk/cgi/oai2')
>>> response = client.ListRecords(metadataPrefix='oai_dc')
Sickle provides different levels of abstraction for working with OAI
responses::
>>> response.xml
<Element {http://www.openarchives.org/OAI/2.0/}OAI-PMH at 0x10469a8c0>
>>> response.raw
u'<?xml version='1.0' encoding ...'
And a convenient way for iterating through all records of a repository:
>>> records = response.iter()
>>> records.next()
<Element {http://www.openarchives.org/OAI/2.0/}record at 0x1051b3b90>
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Sickle-0.1.tar.gz
(4.0 kB
view hashes)