Changes between Version 5 and Version 6 of MultilingualMetadata


Ignore:
Timestamp:
Apr 9, 2009, 8:40:03 AM (15 years ago)
Author:
fxp
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • MultilingualMetadata

    v5 v6  
    3131
    3232== Proposal ==
    33 Metadata is defined by one main language (gmd:MD_Metadata/gmd:language:gco:CharacterString) and other locale (gmd:MD_Metadata/gmd:locale/*).
    3433
    35 If user add new translation, a new local element has to be added:
    36 {{{
    37 <locale>
    38                 <gmd:PT_Locale id="FR">
    39                         <gmd:languageCode><gmd:LanguageCode codeList="#LanguageCode" codeListValue="fra">French</gmd:LanguageCode></gmd:languageCode>                   
    40                         <gmd:characterEncoding><gmd:MD_CharacterSetCode codeList="#MD_CharacterSetCode" codeListValue="utf8">UTF 8</gmd:MD_CharacterSetCode></gmd:characterEncoding>
    41                 </gmd:PT_Locale>
    42         </locale>
    43 }}}
     34Allow multilingual editing in GeoNetwork. One metadata record define :
     35 * one main language (using gmd:language element)
     36 * n other languages (using gmd:locale element)
    4437
    45 Configuration need to set the available languages the editor could use using a list of iso code.
     38[[Image(editor-multilingual.png, 400px)]]
    4639
    47 After editing, the new translated element is stored with:
    48  * an xsi:type= « gmd:PT_FreeText_PropertyType»
    49  * a first gco:CharacterString in the metadata language (in the example en)
    50  * n gmd:PT_FreeText elements with each translation
     40In view mode, according to GUI language :
     41 * if GUI language is available in the metadata, the element is displayed in this language
     42 * else the elemenet is displayed in metadata default language.
    5143
    52 {{{
    53         <scope xsi:type="gmd:PT_FreeText_PropertyType">
    54                 <gco:CharacterString>Codelists for description of metadata datasets compliant with ISO/TC 211 19115:2003 and 19139</gco:CharacterString>
    55                 <gmd:PT_FreeText>
    56                         <gmd:textGroup>
    57                                 <gmd:LocalisedCharacterString locale="#FR ">Listes de codes pour la description de lots de métadonnées conforme ISO TC/211 19115:2003 et 19139</gmd:LocalisedCharacterString>
    58                         </gmd:textGroup>
    59                 </gmd:PT_FreeText>
    60         </scope>
    61 }}}
    62 
    63 
    64 
    65 SchemaLoader should be able to register complexType which are extension based on a PropertyType (and not only a Type). For example :
    66 {{{
    67 <xs:complexType name="PT_FreeText_PropertyType">
    68                 <xs:complexContent>
    69                         <xs:extension base="gco:CharacterString_PropertyType">
    70 }}}
    71 
    72 Then the metadocument should add for all elements which are of type gco:CharacterString_PropertyType an xsi:type option with the list of type available.
    73 {{{
    74 <xs:element name="title" type="gco:CharacterString_PropertyType"/>
    75 }}}
    76 
    77 
    78 For title which is a gco:CharacterString_PropertyType, xsi:type could be :
    79  * gco:CharacterString_PropertyType
    80  * gmd:PT_FreeText_PropertyType
    81 Then if an xsi:type="gmd:PT_FreeText_PropertyType" the element is edited in multilingual mode.
    82 
    83 In the editor any gco:CharacterString could be multilingual. The gco:CharacterString is in default language, the other PT_FreeText elements has to use a locale declared in the metadata document.
    84 
    85 ==== GUI ====
    86 
    87 A list of all available languages is proposed to the user next to all gco:CharacterString elements.
    88 
    89 Label (?)* : _input_field_____  [Language selection list]
    90 
    91 The editor can switch to another language using the selection list and could add a new translation.
    92 
     44Then multilingual content need to be indexed in lucene.
    9345
    9446=== Backwards Compatibility Issues ===
     
    9749
    9850=== Implementation ===
    99 Metadocument (http://localhost:8080/geonetwork/srv/en/metadata.edit!?id=5&) should flag all multilingual elements (mainly gco:CharacterString).
    10051
    101 Current meta-element :
     52Metadata is defined by one main language (gmd:MD_Metadata/gmd:language:gco:CharacterString) and other locale (gmd:MD_Metadata/gmd:locale/*).
     53
     54If user add new translation, a new local element has to be added:
    10255{{{
    103 <gmd:title>
    104   <gco:CharacterString>TITLE
    105     <geonet:element ref="117" min="1" max="1"/>
    106   </gco:CharacterString>
    107   <geonet:element ref="116" min="1" max="1"/>
    108   <geonet:attribute name="gco:nilReason" add="true"/>
    109 </gmd:title>
     56<gmd:locale>
     57  <gmd:PT_Locale id="FR">
     58    <gmd:languageCode><gmd:LanguageCode codeList="#LanguageCode" codeListValue="fra">French</gmd:LanguageCode></gmd:languageCode>                       
     59    <gmd:characterEncoding><gmd:MD_CharacterSetCode codeList="#MD_CharacterSetCode" codeListValue="utf8">UTF 8</gmd:MD_CharacterSetCode></gmd:characterEncoding>
     60  </gmd:PT_Locale>
     61</locale>
     62}}}
     63
     64After editing, the new translated element is stored with:
     65 * an xsi:type= « gmd:PT_FreeText_PropertyType»
     66 * a first gco:CharacterString in the metadata language (in the example "en")
     67 * n gmd:PT_FreeText elements with each translation
     68{{{
     69<scope xsi:type="gmd:PT_FreeText_PropertyType">
     70  <gco:CharacterString>Codelists for description of metadata datasets compliant with ISO/TC 211 19115:2003 and 19139</gco:CharacterString>
     71  <gmd:PT_FreeText>
     72    <gmd:textGroup>
     73      <gmd:LocalisedCharacterString locale="#FR ">Listes de codes pour la description de lots de métadonnées conforme ISO TC/211 19115:2003 et 19139</gmd:LocalisedCharacterString>
     74    </gmd:textGroup>
     75  </gmd:PT_FreeText>
     76</scope>
    11077}}}
    11178
    11279
    113 New meta-element (To be discussed):
     80In the editor any gco:CharacterString could be multilingual. The gco:CharacterString is in default language, the other PT_FreeText elements has to use a locale declared in the metadata document.
     81
     82=== Index ===
     83One index by language is created and specific language analyzer could be define (eg. FrenchAnalyzer, GermanAnalyzer provided by Lucene).
     84Lucene index is stored in WEB-INF/lucene directory :
    11485{{{
    115 <gmd:title>
    116   <gco:CharacterString>TITLE
    117     <geonet:element ref="117" min="1" max="1"/>
    118   </gco:CharacterString>
    119   <geonet:element ref="116" min="1" max="1" multilingual="1"/>
    120   <geonet:attribute name="gco:nilReason" add="true"/>
    121 </gmd:title>
     86lucene
     87 +-- nonspatial_eng
     88 +-- nonspatial_fra
     89 +-- nonspatial_deu
    12290}}}
    12391
     92Metadata indexing is done in default language using index-fields.xsl and multilingual content using language-index-fields.xsl which will extract all fragments to be stored in index.
    12493
     94More details on indexing mechanism MultilingualIndexMechanism .
     95
     96=== Search ===
     97Search is done using a MultiSearcher (ie. in all index) and the index corresponding to GUI language is "boost" to be on top.
     98A duplicate filter filter search result in order to not to have duplicate in results as one record will appear in more than on index.
     99
     100=== Modules: ===
     101 * metadata-iso19139.xsl
     102 * DataManager
     103 * LuceneSearcher
     104 * SearchManager
    125105
    126106== Risks ==