source: FederatedSearch/examples/Example-Resource-with-Custom-Extension.xml @ 4897

Last change on this file since 4897 was 4802, checked in by Oliver Schonefeld, 11 years ago
  • add another custom extension example
  • Property svn:eol-style set to native
  • Property svn:mime-type set to text/xml
File size: 2.5 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<Resource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3    xsi:schemaLocation="http://clarin.eu/fcs/resource ../schema/Resource.xsd
4                        http://clarin.eu/fcs/dataview/hits ../schema/DataView-Hits.xsd"
5    xmlns="http://clarin.eu/fcs/resource"
6    pid="hdl:4711/00-0000-0000-0000-0000-0">
7    <DataView type="application/x-clarin-fcs-hits+xml"
8              ref="http://repos.example.org/corpus1/00-0000-0000-0000-0000-0#S0815">
9        <!--
10            NOTE: File formatted for brevity.
11                  Indention and formatting should be avoided.
12        -->
13        <hits:Result xmlns:hits="http://clarin.eu/fcs/dataview/hits">
14            Und so will ich denn hier auch noch anfÃŒhren, daß ich in diesem
15            Elend das neckische GelÃŒbde getan: man solle, wenn ich uns
16            erlöst und mich wieder zu Hause sÀhe, von mir niemals wieder
17            einen Klagelaut vernehmen ÃŒber den meine freiere Zimmeraussicht
18            beschrÀnkenden Nachbargiebel, den ich vielmehr jetzt recht
19            sehnlich zu erblicken wÃŒnsche; ferner wollt' ich mich ÃŒber
20            Mißbehagen und Langeweile im deutschen Theater nie wieder
21            beklagen, wo man doch immer
22            <hits:Hit>
23                Gott
24            </hits:Hit>
25            danken könne, unter Dach zu sein, was auch auf der BÃŒhne vorgehe.
26        </hits:Result>
27    </DataView>
28   
29    <!--
30        NOTE: this is purely fictional and only serves to demonstrate how
31              to add custom extensions to the result representation
32              within CLARIN-FCS.
33    -->
34
35    <!--
36        Example 1: a hypothetical Endpoint extension for navigation in a result
37        set: it basically provides a set of hrefs, that a GUI can convert into
38        navigation buttions.   
39    -->
40    <nav:navigation xmlns:nav="http://repos.example.org/navigation">
41        <nav:curr href="http://repos.example.org/resultset/4711/4611" />
42        <nav:prev href="http://repos.example.org/resultset/4711/4610" />
43        <nav:next href="http://repos.example.org/resultset/4711/4612" />
44    </nav:navigation>
45   
46    <!--
47       Example 2: a hypothetical Endpoint extension for directly referencing parent
48       resources: it basically provides a link to the parent resource, that can be
49       exploited by an GUI (e.g. build on XSLT/XQuery).
50    -->
51    <parent:Parent xmlns:parent="http://repos.example.org/parent"
52                   ref="http://repos.example.org/path/to/parent/1235.cmdi" />
53</Resource>
Note: See TracBrowser for help on using the repository browser.