Changeset 4677


Ignore:
Timestamp:
03/12/14 17:08:50 (10 years ago)
Author:
Oliver Schonefeld
Message:
  • update Schemas:
    • remove version number from namespace URI (and sanitize them a little)
    • Endpoint Description:
      • change element names <Collection*> to <Resource*>
      • drop <Profile> element
      • add extension points for Endpoint customizations
Location:
FederatedSearch
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • FederatedSearch/examples/Endpoint-Description-Complex.xml

    r4503 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    2 <EndpointDescription xmlns="http://clarin.eu/fcs/1.0/endpoint-description"
     2<EndpointDescription xmlns="http://clarin.eu/fcs/endpoint-description"
    33    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    4     xsi:schemaLocation="http://clarin.eu/fcs/1.0/endpoint-description ../schema/Endpoint-Description.xsd">
    5     <Profile>basic</Profile>
     4    xsi:schemaLocation="http://clarin.eu/fcs/endpoint-description ../schema/Endpoint-Description.xsd"
     5    version="1">
     6    <Capabilities>
     7        <Capability>http://clarin.eu/fcs/capability/basic-search</Capability>
     8    </Capabilities>
    69    <SupportedDataViews>
    7         <SupportedDataView>application/x-clarin-fcs-hits+xml</SupportedDataView>
    8         <SupportedDataView>application/x-cmdi+xml</SupportedDataView>
     10        <SupportedDataView id="dv1">application/x-clarin-fcs-hits+xml</SupportedDataView>
     11        <SupportedDataView id="dv2">application/x-cmdi+xml</SupportedDataView>
    912    </SupportedDataViews>
    10     <Collections>
    11         <Collection pid="hdl:10932/goethe">
     13    <Resources>
     14        <Resource pid="hdl:10932/goethe">
    1215            <Title xml:lang="de">Goethe Corpus</Title>
    1316            <Title xml:lang="en">Goethe Korpus</Title>
     
    1821                <Language>deu</Language>
    1922            </Languages>
    20         </Collection>
    21         <Collection pid="hdl:10932/mannheimer_morgen">
     23        </Resource>
     24        <Resource pid="hdl:10932/mannheimer_morgen">
    2225            <Title xml:lang="de">Mannheimer Morgen newspaper Corpus</Title>
    2326            <Title xml:lang="en">Zeitungskorpus des Mannheimer Morgen</Title>
     
    2629                <Language>deu</Language>
    2730            </Languages>
    28             <Collections>
    29                 <Collection pid="hdl:10932/mannheimer_morgen_before_1990">
     31            <Resources>
     32                <Resource pid="hdl:10932/mannheimer_morgen_before_1990">
    3033                    <Title xml:lang="de">Mannheimer Morgen newspaper Corpus (before 1990)</Title>
    3134                    <Title xml:lang="en">Zeitungskorpus des Mannheimer Morgen (vor 1990)</Title>
     
    3437                        <Language>deu</Language>
    3538                    </Languages>
    36                 </Collection>
    37                 <Collection pid="hdl:10932/mannheimer_morgen_after_1990">
     39                </Resource>
     40                <Resource pid="hdl:10932/mannheimer_morgen_after_1990">
    3841                    <Title xml:lang="de">Mannheimer Morgen newspaper Corpus (after 1990)</Title>
    3942                    <Title xml:lang="en">Zeitungskorpus des Mannheimer Morgen (nach 1990)</Title>
     
    4245                        <Language>deu</Language>
    4346                    </Languages>
    44                 </Collection>
    45             </Collections>
    46         </Collection>
    47     </Collections>
     47                </Resource>
     48            </Resources>
     49        </Resource>
     50    </Resources>
    4851</EndpointDescription>
  • FederatedSearch/examples/Endpoint-Description-Simple.xml

    r4395 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    2 <EndpointDescription xmlns="http://clarin.eu/fcs/1.0/endpoint-description"
     2<EndpointDescription xmlns="http://clarin.eu/fcs/endpoint-description"
    33    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    4     xsi:schemaLocation="http://clarin.eu/fcs/1.0/endpoint-description ../schema/Endpoint-Description.xsd">
    5     <Profile>basic</Profile>
     4    xsi:schemaLocation="http://clarin.eu/fcs/endpoint-description ../schema/Endpoint-Description.xsd"
     5    version="1">
     6    <Capabilities>
     7        <Capability>http://clarin.eu/fcs/capability/basic-search</Capability>
     8        <Capability>http://clarin.eu/fcs/capability/a-b</Capability>
     9    </Capabilities>
    610    <SupportedDataViews>
    7         <SupportedDataView>application/x-clarin-fcs-hits+xml</SupportedDataView>
     11        <SupportedDataView id="dv1">application/x-clarin-fcs-hits+xml</SupportedDataView>
    812    </SupportedDataViews>
    9     <Collections>
    10         <Collection pid="hdl:10932/goethe">
     13    <Resources>
     14        <Resource pid="hdl:10932/goethe">
    1115            <Title xml:lang="de">Goethe Corpus</Title>
    1216            <Title xml:lang="en">Goethe Korpus</Title>
     
    1721                <Language>deu</Language>
    1822            </Languages>
    19         </Collection>
    20     </Collections>
     23        </Resource>
     24    </Resources>
    2125</EndpointDescription>
  • FederatedSearch/examples/Example-Resource-with-Custom-Extension.xml

    r4496 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    22<Resource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    3     xsi:schemaLocation="http://clarin.eu/fcs/1.0 ../schema/Resource.xsd
    4                         http://clarin.eu/fcs/1.0/hits ../schema/DataView-HITS.xsd"
    5     xmlns="http://clarin.eu/fcs/1.0"
     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"
    66    pid="hdl:4711/00-0000-0000-0000-0000-0">
    77    <DataView type="application/x-clarin-fcs-hits+xml"
     
    1111                  Indention and formatting should be avoided.
    1212        -->
    13         <hits:Result xmlns:hits="http://clarin.eu/fcs/1.0/hits">
     13        <hits:Result xmlns:hits="http://clarin.eu/fcs/dataview/hits">
    1414            Und so will ich denn hier auch noch anfÃŒhren, daß ich in diesem
    1515            Elend das neckische GelÃŒbde getan: man solle, wenn ich uns
  • FederatedSearch/examples/Example-Resource.xml

    r4496 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    22<Resource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    3     xsi:schemaLocation="http://clarin.eu/fcs/1.0 ../schema/Resource.xsd
    4                         http://clarin.eu/fcs/1.0/hits ../schema/DataView-HITS.xsd"
    5     xmlns="http://clarin.eu/fcs/1.0"
     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"
    66    pid="hdl:4711/00-0000-0000-0000-0000-0">
    77    <DataView type="application/x-clarin-fcs-hits+xml"
     
    1111                  Indention and formatting should be avoided.
    1212        -->
    13         <hits:Result xmlns:hits="http://clarin.eu/fcs/1.0/hits">
     13        <hits:Result xmlns:hits="http://clarin.eu/fcs/dataview/hits">
    1414            Und so will ich denn hier auch noch anfÃŒhren, daß ich in diesem
    1515            Elend das neckische GelÃŒbde getan: man solle, wenn ich uns
  • FederatedSearch/examples/Resource-Hit-Multi-Hit.xml

    r4395 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    2 <Result xmlns="http://clarin.eu/fcs/1.0/hits"
     2<Result xmlns="http://clarin.eu/fcs/dataview/hits"
    33    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    4     xsi:schemaLocation="http://clarin.eu/fcs/1.0/hits ../schema/Resource-Hits.xsd">
     4    xsi:schemaLocation="http://clarin.eu/fcs/dataview/hits ../schema/DataView-Hits.xsd">
    55    The quick brown <Hit>fox</Hit> jumps over the lazy <Hit>dog</Hit>.
    66</Result>
  • FederatedSearch/examples/Resource-Hit-Single.xml

    r4395 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    2 <Result xmlns="http://clarin.eu/fcs/1.0/hits"
     2<Result xmlns="http://clarin.eu/fcs/dataview/hits"
    33    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    4     xsi:schemaLocation="http://clarin.eu/fcs/1.0/hits ../schema/Resource-Hits.xsd">
     4    xsi:schemaLocation="http://clarin.eu/fcs/dataview/hits ../schema/DataView-Hits.xsd">
    55    The quick brown <Hit>fox</Hit> jumps over the lazy dog.
    66</Result>
  • FederatedSearch/schema/DataView-Hits.xsd

    r4503 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    22<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
     3    xmlns:h="http://www.w3.org/1999/xhtml"
    34    xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning"
    45    xmlns:hits="http://clarin.eu/fcs/1.0/hits"
    5     xmlns:h="http://www.w3.org/1999/xhtml"
    66    xml:lang="en" vc:minVersion="1.0" vc:maxVersion="1.1"
    7     targetNamespace="http://clarin.eu/fcs/1.0/hits" elementFormDefault="qualified">
     7    targetNamespace="http://clarin.eu/fcs/dataview/hits" elementFormDefault="qualified">
    88
    99    <xs:annotation>
  • FederatedSearch/schema/Endpoint-Description.xsd

    r4534 r4677  
    11<?xml version="1.0" encoding="UTF-8"?>
    22<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
     3    xmlns:h="http://www.w3.org/1999/xhtml"
    34    xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning"
    4     xmlns:ed="http://clarin.eu/fcs/1.0/endpoint-description" elementFormDefault="qualified"
    5     xmlns:h="http://www.w3.org/1999/xhtml"
    6     xml:lang="en" vc:minVersion="1.0" vc:maxVersion="1.1"
    7     targetNamespace="http://clarin.eu/fcs/1.0/endpoint-description">
    8     <xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd" />
     5    xmlns:ed="http://clarin.eu/fcs/endpoint-description"
     6    xml:lang="en"
     7    vc:minVersion="1.0" vc:maxVersion="1.1"
     8    elementFormDefault="qualified"
     9    targetNamespace="http://clarin.eu/fcs/endpoint-description">
     10    <xs:import namespace="http://www.w3.org/XML/1998/namespace"
     11               schemaLocation="http://www.w3.org/2001/xml.xsd" />
    912
    1013    <xs:annotation>
     
    4447        <xs:complexType>
    4548            <xs:sequence>
    46                 <!-- Profile -->
    47                 <xs:element name="Profile">
    48                     <xs:annotation>
    49                         <xs:documentation>
    50                             <h:p> The CLARIN-FCS profile, that is supported
    51                                 by an Endpoint. </h:p>
    52                         </xs:documentation>
    53                     </xs:annotation>
    54                     <xs:simpleType>
    55                         <xs:restriction base="xs:string">
    56                             <xs:enumeration value="basic">
     49                <!-- Capabilities -->
     50                <xs:element name="Capabilities">
     51                    <xs:annotation>
     52                        <xs:documentation>
     53                            <h:p>A list of Capabilities, that are supported by this Endpoint.</h:p>
     54                        </xs:documentation>
     55                    </xs:annotation>
     56                    <xs:complexType>
     57                        <xs:sequence>
     58                            <xs:element name="Capability" maxOccurs="unbounded">
    5759                                <xs:annotation>
    5860                                    <xs:documentation>
    59                                         <h:p> The Endpoint supports the
    60                                             <h:em>basic</h:em>
    61                                             CLARIN-FCS profile. </h:p>
     61                                        A Capability, encoded by an URI, that is supported by this Endpoint.
     62                                        For valid URIs, consult the CLARIN-FCS specification.
    6263                                    </xs:documentation>
    6364                                </xs:annotation>
    64                             </xs:enumeration>
    65                             <!-- 'extended' is not yet defined -->
    66                             <!--
    67                             <xs:enumeration value="extended">
    68                                 <xs:annotation>
    69                                     <xs:documentation>
    70                                         <h:p> The Endpoint supports the
    71                                             <h:em>extended</h:em>
    72                                             CLARIN-FCS profile. </h:p>
    73                                     </xs:documentation>
    74                                 </xs:annotation>
    75                             </xs:enumeration>
    76                             -->
    77                         </xs:restriction>
    78                     </xs:simpleType>
    79                 </xs:element>
    80 
     65                                <xs:simpleType>
     66                                    <xs:restriction base="xs:anyURI">
     67                                        <xs:pattern value="http://clarin.eu/fcs/capability/\w([\.\-]{0,1}\w)*" />
     68                                    </xs:restriction>
     69                                </xs:simpleType>
     70                            </xs:element>
     71                        </xs:sequence>
     72                    </xs:complexType>
     73                </xs:element>
     74
     75                <!-- SupportedDataViews -->
    8176                <xs:element name="SupportedDataViews">
    8277                    <xs:annotation>
     
    9186                                <xs:annotation>
    9287                                    <xs:documentation>
    93                                         The MIME type of a supported DataView.
     88                                        The MIME type of a supported Data View.
    9489                                    </xs:documentation>
    9590                                </xs:annotation>
    96                                 <xs:simpleType>
    97                                     <xs:restriction base="xs:string">
    98                                         <xs:pattern value="\w+/\w([\.\-]{0,1}\w)*(\+\w+){0,1}"/>
    99                                     </xs:restriction>
    100                                 </xs:simpleType>
     91                                <xs:complexType>
     92                                    <xs:simpleContent>
     93                                        <xs:extension base="ed:mimetypeString">
     94                                            <xs:attribute name="id" type="xs:ID" use="required" />
     95                                        </xs:extension>
     96                                    </xs:simpleContent>
     97                                </xs:complexType>
    10198                            </xs:element>
    10299                        </xs:sequence>
    103100                    </xs:complexType>
    104101                </xs:element>
    105                 <!-- Collections -->
    106                 <xs:element ref="ed:Collections">
    107                     <xs:annotation>
    108                         <xs:documentation>
    109                             <h:p>
    110                                 A list of top-level collections, that are available
     102               
     103                <!-- Resources -->
     104                <xs:element ref="ed:Resources">
     105                    <xs:annotation>
     106                        <xs:documentation>
     107                            <h:p>
     108                                A list of top-level resources, that are available
    111109                                at an Endpoint. An Endpoint MUST
    112                                 declare at least one top-level collection.
    113                             </h:p>
    114                         </xs:documentation>
    115                     </xs:annotation>
    116                 </xs:element>
     110                                declare at least one top-level resource.
     111                            </h:p>
     112                        </xs:documentation>
     113                    </xs:annotation>
     114                </xs:element>
     115
     116                <!-- extension point -->
     117                <xs:any namespace="##other" processContents="skip" minOccurs="0" maxOccurs="unbounded">
     118                    <xs:annotation>
     119                        <xs:documentation>
     120                            <h:p>
     121                                Extension point to allow Endpoints to embed custom data in the Endpoint Description.
     122                                CLARIN-FCS clients SHOULD ignore any data they do not understand. 
     123                            </h:p>
     124                        </xs:documentation>
     125                    </xs:annotation>
     126                </xs:any>
    117127            </xs:sequence>
     128            <xs:attribute name="version" type="xs:nonNegativeInteger" use="required">
     129                <xs:annotation>
     130                    <xs:documentation>
     131                        <h:p>
     132                            Version used for Endpoint Description. Endpoints MUST use the value "1".
     133                        </h:p>
     134                    </xs:documentation>
     135                </xs:annotation>
     136            </xs:attribute>
    118137        </xs:complexType>
    119138    </xs:element>
    120139
    121     <xs:element name="Collections">
     140    <xs:element name="Resources">
    122141        <xs:annotation>
    123142            <xs:documentation>
    124143                <h:p>
    125                     A list of collections, that are available
     144                    A list of resources, that are available
    126145                    at an Endpoint. An Endpoint MUST
    127                     declare at least one collection.
     146                    declare at least one resource.
    128147                </h:p>
    129148            </xs:documentation>
     
    131150        <xs:complexType>
    132151            <xs:sequence>
    133                 <xs:element ref="ed:Collection" maxOccurs="unbounded"/>
     152                <xs:element ref="ed:Resource" maxOccurs="unbounded"/>
    134153            </xs:sequence>                           
    135154        </xs:complexType>
    136155    </xs:element>
    137156
    138     <xs:element name="Collection">
     157    <xs:element name="Resource">
    139158        <xs:annotation>
    140159            <xs:documentation>
    141160                <h:p>
    142                     Detailed description of a collection that is available at an
    143                     Endpoint. A collection is a searchable
     161                    Detailed description of a resource that is available at an
     162                    Endpoint. A resource is a searchable
    144163                    entity at an Endpoint, e.g. a single corpus.
    145164                </h:p>
     
    152171                        <xs:documentation>
    153172                            <h:p>
    154                                 A human readable title for the corpus. An English version is
     173                                A human readable title for the resource. An English version is
    155174                                mandatory.
    156175                            </h:p>
     
    158177                    </xs:annotation>
    159178                </xs:element>
     179               
    160180                <xs:element name="Description" type="ed:i18nString" minOccurs="0" maxOccurs="unbounded">
    161181                    <xs:annotation>
    162182                        <xs:documentation>
    163183                            <h:p>
    164                                 An optional human-readable description of the collection. Is should
     184                                An optional human-readable description of the resource. Is should
    165185                                be at most one sentence. If supplied, an English version is
    166186                                mandatory.
     
    169189                    </xs:annotation>
    170190                </xs:element>
     191               
    171192                <xs:element name="LandingPageURI" type="xs:anyURI" minOccurs="0">
    172193                    <xs:annotation>
    173194                        <xs:documentation>
    174195                            <h:p>
    175                                 A link to a website for this collection, e.g. a landing page for a corpus.
    176                             </h:p>
    177                         </xs:documentation>
    178                     </xs:annotation>
    179                 </xs:element>
     196                                A link to a website for the resource, e.g. a landing page for a corpus.
     197                            </h:p>
     198                        </xs:documentation>
     199                    </xs:annotation>
     200                </xs:element>
     201               
    180202                <xs:element name="Languages">
    181203                    <xs:annotation>
    182204                        <xs:documentation>
    183205                            <h:p>
    184                                 The (relevant) languages available <h:em>within</h:em> the collection.
     206                                The (relevant) languages available <h:em>within</h:em> the resource.
    185207                            </h:p>
    186208                        </xs:documentation>
     
    194216                                            A ISO 639-3 three letter language code. This
    195217                                            element should be repeated for all languages
    196                                             (relevant) available <h:em>within</h:em> the collection.
     218                                            (relevant) available <h:em>within</h:em> the resource.
    197219                                        </p>
    198220                                    </xs:documentation>
     
    207229                    </xs:complexType>
    208230                </xs:element>
    209                 <xs:element ref="ed:Collections" minOccurs="0">
    210                     <xs:annotation>
    211                         <xs:documentation>
    212                             <h:p>
    213                                 If a collection has searchable sub-collections
     231
     232                <xs:element ref="ed:Resources" minOccurs="0">
     233                    <xs:annotation>
     234                        <xs:documentation>
     235                            <h:p>
     236                                If a resource has searchable sub-resources
    214237                                the Endpoint MUST supply additional finer grained
    215                                 collection elements. A sub-collection is a
    216                                 searchable entity within a collection, e.g. a sub-corpus.
    217                             </h:p>
    218                         </xs:documentation>
    219                     </xs:annotation>
    220                 </xs:element>
     238                                &lt;Resource&gt; elements. A sub-resource is a
     239                                searchable entity within a resource, e.g. a sub-corpus.
     240                            </h:p>
     241                        </xs:documentation>
     242                    </xs:annotation>
     243                </xs:element>
     244
     245                <!-- extension point -->
     246                <xs:any namespace="##other" processContents="skip" minOccurs="0" maxOccurs="unbounded">
     247                    <xs:annotation>
     248                        <xs:documentation>
     249                            <h:p>
     250                                Extension point to allow Endpoints to embed custom data in the Endpoint Description
     251                                for a specific resource. CLARIN-FCS clients SHOULD ignore any data they do not understand. 
     252                            </h:p>
     253                        </xs:documentation>
     254                    </xs:annotation>
     255                </xs:any>
    221256            </xs:sequence>
    222257            <xs:attribute name="pid" type="xs:anyURI" use="required">
     
    224259                    <xs:documentation>
    225260                        <h:p>
    226                             The persistent identifier of this collection. This
     261                            The persistent identifier of this resource. This
    227262                            value MUST be the same as the <h:code>MdSelfLink</h:code>
    228263                            of the CMDI record describing the collection.
     
    234269    </xs:element>
    235270
     271    <xs:simpleType name="mimetypeString">
     272        <xs:restriction base="xs:string">
     273            <xs:pattern value="\w+/\w([\.\-]{0,1}\w)*(\+\w+){0,1}" />
     274        </xs:restriction>
     275    </xs:simpleType>
     276
    236277    <xs:complexType name="i18nString">
    237278        <xs:simpleContent>
  • FederatedSearch/schema/Resource.xsd

    r4503 r4677  
    22<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
    33    xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning"
    4     xmlns:fcs="http://clarin.eu/fcs/1.0"
    54    xmlns:h="http://www.w3.org/1999/xhtml"
     5    xmlns:fcs="http://clarin.eu/fcs/resource"
    66    xml:lang="en" vc:minVersion="1.0" vc:maxVersion="1.1"
    7     targetNamespace="http://clarin.eu/fcs/1.0" elementFormDefault="qualified">
     7    targetNamespace="http://clarin.eu/fcs/resource" elementFormDefault="qualified">
     8
    89    <xs:annotation>
    910        <xs:documentation>
     
    5051    <xs:complexType name="ResourceType">
    5152        <xs:sequence>
    52             <!--
    53               As long as there is no clear use-case, don't allow recursive Resources
    54               <xs:element name="Resource" minOccurs="0" maxOccurs="unbounded" type="fcs:ResourceType"/>
    55             -->
    5653            <xs:element name="DataView" type="fcs:DataViewType" minOccurs="0" maxOccurs="unbounded" />
    5754            <xs:element name="ResourceFragment" minOccurs="0" maxOccurs="unbounded">
Note: See TracChangeset for help on using the changeset viewer.