OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

search-ws message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [search-ws] Groups - atom-extension-for-sru.xml uploaded


Ray,

> Please look at the sample XML file intended as an ATOM extension for SRU. 
> For discussion Monday.

If I've read the XML right, then I think the atom:entry elements
are missing an atom:content element.

The Atom spec says that an atom:entry that does not contain an 
atom:content element must contain at least one atom:link element
with a rel attribute of alternate.

I think in our case it would be best to put the SRU stuff inside
an atom:content element as follows:

<feed ...>
   ...
   <sru:numberOfRecords>2</sru:numberOfRecords>
   <entry>
     ....
     <content type="application/xml">
       <sru:recordSchema>info:srw/schema/1/dc-v1.1</sru:recordSchema>
       <sru:recordPacking>xml</sru:recordPacking>
       <sru:recordData>
         <dc ...>
         </dc>
       </sru:recordData>
     </content>
     <sru:recordPosition>1</sru:recordPosition>
   </entry>
   ....
</feed>

But actually, there may be no need for all the sru:record* elements
inside the atom:content. You could perhaps just say:

<feed ..>
   ....
   <sru:numberOfRecords>2</sru:numberOfRecords>
   <entry>
     ....
     <content type="application/xml">
       <dc ...>
       </dc>
     </content>
     <sru:recordPosition>1</sru:recordPosition>
   </entry>
   ....
</feed>

So, I think that all you need to add to an Atom Feed to support a result
set, is the number of records in the result set, and a record number
to each entry. It maybe that if the record count is an estimate, then
you'd want a marker when you reached the end record?

Ashley.

--- first record from the original xml -----
<entry>
     <title>Don't panic : Douglas Adams and the hitchiker's guide to the 
galaxy </title>
     <link href="..."/>
     <id>URN:ISBN:1840235012</id>
     <sru:recordSchema>info:srw/schema/1/dc-v1.1</sru:recordSchema>
     <sru:recordPacking>xml</sru:recordPacking>
     <sru:recordData>
       <dc xmlns="info:srw/schema/1/dc-schema" 
schemaLocation="info:srw/schema/1/dc-schema 
http://www.loc.gov/standards/sru/resources/dc-schema.xsd";>
         <title> Don't panic : Douglas Adams and the hitchiker's guide 
to the galaxy </title>
         <creator>Gaiman, Neil.</creator>
         <type>text</type>
         <publisher>London : Titan,</publisher>
         <date>2002.</date>
         <language>eng</language>
         <subject>Adams, Douglas, 1952-2001.</subject>
         <subject>
Adams, Douglas, 1952-2001. Hitch-hiker's guide to the galaxy.
</subject>
         <subject>Science fiction, English--History and criticism.</subject>
         <subject>Novelists, English--20th century--Biography.</subject>
         <subject>Prefect, Ford (Fictitious character)</subject>
         <subject>Dent, Arthur (Fictitious character)</subject>
         <identifier>URN:ISBN:1840235012</identifier>
       </dc>
     </sru:recordData>
     <sru:recordPosition>1</sru:recordPosition>
   </entry>
---------------------

-- 
Ashley Sanders               a.sanders@manchester.ac.uk
Copac http://copac.ac.uk A Mimas service funded by JISC


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]