Version 1.1, 12th January 2004
These messages are the equivalents of the SRW examples. For more information about the differences between SRW and SRU, see the SRU page.
The first operation would normally be the Explain operation. A typical Explain request would be:
http://srw.cheshire3.org:8080/l5r?version=1.1&operation=explain |
The corresponding response from the server would be:
<SRW:explainResponse xmlns:SRW="http://www.loc.gov/zing/srw/">
<SRW:version>1.1</SRW:version>
<SRW:record>
<SRW:recordSchema>http://explain.z3950.org/dtd/2.0/</SRW:recordSchema>
<SRW:recordPacking>string</SRW:recordPacking>
<SRW:recordData>
<explain id="org.o-r-g.srw-first"
authoritative="true">
<serverInfo wsdl="http://srw.o-r-g.org/wsdlfile.txt"
protocol="SRU" version="1.1">
<host>srw.cheshire3.org</host>
<port>8080</port>
<database numRecs="100" lastUpdate="2002-08-18 11:30:00">
/l5r
</database>
</serverInfo>
...
</SRW:recordData>
</SRW:record>
</SRW:explainResponse>
|
Subsequent operations might be searchRetrieve operations. A typical searchRetrieve request might be:
http://srw.cheshire3.org:8080/l5r?operation=searchRetrieve&version=1.1&startRecord=1 &query=dc.author exact jones and dc.title >=sword&maximumRecords=10&recordSchema=mods |
The searchRetreive response would be of the form:
<SRW:searchRetrieveResponse xmlns:SRW="http://www.loc.gov/zing/srw/"
xmlns:DIAG="http://www.loc.gov/zing/srw/diagnostics/">
<SRW:version>1.1</SRW:version>
<SRW:numberOfRecords>2</SRW:numberOfRecords>
<SRW:resultSetId>8c527d60-c3b4-4cec-a1de-1ff80a5932df</SRW:resultSetId>
<SRW:resultSetIdleTime>600</SRW:resultSetIdleTime>
<SRW:records>
<SRW:record>
<SRW:recordSchema>http://www.loc.gov/mods/</SRW:recordSchema>
<SRW:recordPacking>string</SRW:recordPacking>
<SRW:recordData>
<?xml version="1.0" encoding="UTF-8"?>
<mods xmlns:xlink="http://www.w3.org/TR/xlink"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.loc.gov/mods/"
xsi:schemaLocation="http://www.loc.gov/standards/mods/mods.xsd">
<titleInfo>
<title>Sound and fury : the making of the punditocracy /</title>
</titleInfo>
<name type="personal">
<namePart>Alterman, Eric.</namePart>
<role>creator</role>
</name>
...
</SRW:recordData>
<SRW:recordNumber>1</SRW:recordNumber>
</SRW:record>
<SRW:record>
<SRW:recordSchema>http://www.loc.gov/zing/srw/diagnostics/</SRW:recordSchema>
<SRW:recordPacking>string</SRW:recordPacking>
<SRW:recordData>
<diagnostic> |
The other operation that can occur is scan. SOAP examples:
http://srw.cheshire3.org:8080/l5r?operation=scan&version=1.1&scanClause=dc.author any jones &maximumTerms=20&responsePosition=1 |
And the response:
<SRW:scanResponse xmlns:SRW="http://www.loc.gov/zing/srw/">
<SRW:version>1.1</SRW:version>
<SRW:terms>
<SRW:term>
<SRW:value>jones</SRW:value>
<SRW:numberOfRecords>234</SRW:numberOfRecords>
<SRW:/term>
<SRW:term>
<SRW:value>jonty</SRW:value>
<SRW:numberOfRecords>56</SRW:numberOfRecords>
<SRW:/term>
...
</SRW:terms>
</SRW:scanResponse>
|