# HG changeset patch # User Josef Willenborg # Date 1299846842 -3600 # Node ID d6f528ad5d968918547c4ee97f2b4517f8b089de # Parent 59ff47d1e237e24b981820b862ccefa64676921d TEI Unterst?tzung, Fehlerbehebungen, externe Objekte diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/_stuff/tmp/mathML.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/software/eXist/webapp/mpdl/_stuff/tmp/mathML.html Fri Mar 11 13:34:02 2011 +0100 @@ -0,0 +1,69 @@ + + + + + + + + Example of MathML embedded in an XHTML file + + +

Example of MathML embedded in an XHTML file

+ + +

+ Given the quadratic equation + + + a + + + x + 2 + + + + b + + x + + + c + + + , the roots are given by + + + x + = + + + + b + ± + + + b + 2 + + + 4 + + a + + c + + + + 2 + + a + + + + + . +

+ + + diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/attribute-query-result.xql --- a/software/eXist/webapp/mpdl/attribute-query-result.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/attribute-query-result.xql Fri Mar 11 13:34:02 2011 +0100 @@ -7,6 +7,8 @@ declare namespace request="http://exist-db.org/xquery/request"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; + declare namespace dc="http://purl.org/dc/elements/1.1/"; declare namespace dct="http://purl.org/dc/terms/1.0/"; declare namespace rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"; @@ -43,28 +45,47 @@ let $docBaseArch := "archimedes" let $docBaseEcho := "echo" +let $docBaseTei := "tei" let $fulltextMorphArchDocPath := concat($docPathMorph, "/", $docBaseArch, "/", $language) let $fulltextMorphEchoDocPath := concat($docPathMorph, "/", $docBaseEcho, "/", $language) +let $fulltextMorphTeiDocPath := concat($docPathMorph, "/", $docBaseTei, "/", $language) let $fulltextMorphCollection := - if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho)) + if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphArchDocPath, $fulltextMorphEchoDocPath, $fulltextMorphTeiDocPath) + else if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then collection($fulltextMorphArchDocPath, $fulltextMorphEchoDocPath) - else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho))) + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphArchDocPath, $fulltextMorphTeiDocPath) + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphEchoDocPath, $fulltextMorphTeiDocPath) + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and not(contains($docbase, $docBaseTei))) then collection($fulltextMorphArchDocPath) - else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho)) + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then collection($fulltextMorphEchoDocPath) + else if(not(contains($docbase, $docBaseArch)) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphTeiDocPath) else () let $fulltextStandardArchDocPath := concat($docPathStandard, "/", $docBaseArch) let $fulltextStandardEchoDocPath := concat($docPathStandard, "/", $docBaseEcho) +let $fulltextStandardTeiDocPath := concat($docPathStandard, "/", $docBaseTei) let $fulltextStandardCollectionStr := - if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho)) + if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardArchDocPath, "', '", $fulltextStandardEchoDocPath, "', '", $fulltextStandardTeiDocPath, "')") + else if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then concat("collection('", $fulltextStandardArchDocPath, "', '", $fulltextStandardEchoDocPath, "')") - else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho))) + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardArchDocPath, "', '", $fulltextStandardTeiDocPath, "')") + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardEchoDocPath, "', '", $fulltextStandardTeiDocPath, "')") + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and not(contains($docbase, $docBaseTei))) then concat("collection('", $fulltextStandardArchDocPath, "')") - else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho)) + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then concat("collection('", $fulltextStandardEchoDocPath, "')") + else if(not(contains($docbase, $docBaseArch)) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardTeiDocPath, "')") else "" -let $metadataStr := concat("(", $fulltextStandardCollectionStr, "/archimedes/info", "|" , $fulltextStandardCollectionStr, "/echo:echo/echo:metadata", ")") +let $metadataStr := concat("(", $fulltextStandardCollectionStr, "/archimedes/info", "|" , $fulltextStandardCollectionStr, "/echo:echo/echo:metadata", "|" , $fulltextStandardCollectionStr, "/TEI:TEI/TEI:teiHeader", ")") let $fulltextStandardCollection := if($fulltextStandardCollectionStr != "") then util:eval($fulltextStandardCollectionStr) diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/doc/doc-operation-exist.xql --- a/software/eXist/webapp/mpdl/doc/doc-operation-exist.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/doc/doc-operation-exist.xql Fri Mar 11 13:34:02 2011 +0100 @@ -114,6 +114,7 @@ let $docBaseOptionsSelected := for $option in $docBaseOptions/option @@ -175,7 +176,7 @@ if ($error = 'no') then
- +
@@ -184,9 +185,28 @@ @@ -253,7 +253,7 @@

{$title}

{$resultHtml} -
+
See the XQuery source of this page, if you find a bug let us know \ No newline at end of file diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/info.xql --- a/software/eXist/webapp/mpdl/info.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/info.xql Fri Mar 11 13:34:02 2011 +0100 @@ -33,7 +33,7 @@ else if ($info = 'malcolm') then (

Malcolm HymanDr. Malcolm Hyman
† September 4, 2009

,

In memoriam

, 'This software is dedicated to Malcolm Hyman, who was the founder and leader of this project. He died suddenly and unexpectedly. This project owes everything to him.',

His homepages

, ) else if ($info = 'docBases') - then (Archimedes DTD (until 2008): , 'more than 120 documents (4KB - 18MB), coming from Echo collections "Archimedes" and "Historical Travel Guides", languages: latin, italian, english, german, french, dutch, greek, arabic, chinese',
,
, Echo Schema (since2009): , 'planned more than 100 documents in different languages') + then (Archimedes DTD (until 2008): , 'more than 120 documents (4KB - 18MB), coming from Echo collections "Archimedes" and "Historical Travel Guides", languages: latin, italian, english, german, french, dutch, greek, arabic, chinese',
,
, Echo Schema (since 2009): , 'planned more than 100 documents in different languages',
,
, TEI Schema (since 2011): , 'different languages, mainly by external document providers') else if ($info = 'attr') then ('Attribute search is case sensitive.',

, 'Query syntax see: ', Lucene query syntax, '.') else if ($info = 'fulltextMorph') @@ -53,7 +53,7 @@ else if ($info = 'docInterfaceOperation') then (

MPDL document interface: Operation
Please do not overload the system by executing too many document operations at the same time. Please finish one document operation after the other. Look into the status of your document operation (each one has a job id) and see if it is finished (job status finished has a time stamp). Then start another operation.

) else if ($info = 'docInterfaceSource') - then (

MPDL document interface: Source document
The source document has to be a valid XML-document against either the Echo schema (see the Echo Relax NG Schema) or against the Archimedes document format

) + then (

MPDL document interface: Source document
The source document has to be a valid XML-document against either the Echo Schema or against the TEI Lite schema or against the Archimedes document format

) else if ($info = 'docInterfaceDestDocName') then (

MPDL document interface: Destination document name

) else () diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/interface/doc-query.xql --- a/software/eXist/webapp/mpdl/interface/doc-query.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/interface/doc-query.xql Fri Mar 11 13:34:02 2011 +0100 @@ -41,12 +41,6 @@ let $currentTimeBegin := util:system-time() let $documentAvailable := doc-available($fullDocumentUri) let $document := doc($fullDocumentUri) -let $metadata := - if ($docbase = 'archimedes') - then $document/archimedes/info - else if ($docbase = 'echo') - then $document/echo:echo/echo:metadata - else '' (: xQuery inline execution does not work in module so it has to be done here :) let $xQueryPageSize := 100 diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/interface/echo/echoDocuView.xql --- a/software/eXist/webapp/mpdl/interface/echo/echoDocuView.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/interface/echo/echoDocuView.xql Fri Mar 11 13:34:02 2011 +0100 @@ -6,7 +6,7 @@ let $mpdlDocUri := request:get-parameter("document", ()) let $echoArchivePath := mpdl-text:getEchoArchivePath($mpdlDocUri) -let $echoURLDocuView := concat("http://mpdl-dev.mpiwg-berlin.mpg.de/ECHOdocuView?url=", $echoArchivePath) +let $echoURLDocuView := concat("http://mpdl-dev.mpiwg-berlin.mpg.de/ECHOdocuView?url=", $echoArchivePath, "&optionToggle=1") let $urlDocuViewer := redirect to Echo let $diglibAvailable := if ($echoArchivePath = "XXXXDigilibNotAvailableXXXX") diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/interface/lt/wordInfo.xql --- a/software/eXist/webapp/mpdl/interface/lt/wordInfo.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/interface/lt/wordInfo.xql Fri Mar 11 13:34:02 2011 +0100 @@ -7,7 +7,7 @@ (: TODO: Verlinkung von lemma, form, weiteren Einheiten in den Infos auf mpdl-proto (HTML und XML) :) -let $type := request:get-parameter("type", "all") +let $type := request:get-parameter("type", "compact") let $language := request:get-parameter("language", "") let $word := request:get-parameter("word", "") let $placeHref := request:get-parameter("placeHref", "") @@ -21,7 +21,10 @@ then ("no lemmas found for your query") else for $lemma in $lemmas/lemmas/lemma - let $lemmaText := concat($lemma/lemma-name, " (", $lemma/provider, ")") + let $lemmaText := + if ($type = "compact") + then $lemma/lemma-name + else concat($lemma/lemma-name, " (", $lemma/provider, ")") let $orderedFormsStrTmp := for $form in $lemma/forms/form let $formStr := concat($form/form-name, " (", $form/provider, ")") @@ -35,12 +38,18 @@ then concat("http://www.perseus.tufts.edu/hopper/morph?l=", $lemma/lemma-name, "&la=greek") else "" let $lemmaLi := - if ($language = "ar" or $language = "el" or $language = "la") + if (($type = "all" or $type = "morph") and ($language = "ar" or $language = "el" or $language = "la")) then -
  • Lemma: {$lemmaText} (see this entry in www.perseus.tufts.edu) +
  • Lemma: {$lemmaText} (external link to www.perseus.tufts.edu)
      {$orderedFormsStr}
  • - else + else if ($type ="compact" and ($language = "ar" or $language = "el" or $language = "la")) + then +
  • Lemma: {$lemmaText} (external link to www.perseus.tufts.edu)
  • + else if ($type ="compact") + then +
  • Lemma: {$lemmaText}
  • + else
  • Lemma: {$lemmaText}
      {$orderedFormsStr}
  • @@ -81,7 +90,7 @@ let $lemmasStrTokenized := tokenize($lemmasStr, " ") let $dictionariesLocal := - if ($type = "all" or $type = "dict") + if ($type = "all" or $type = "compact" or $type = "dict") then mpdltext:get-lex-entries-by-lucene-query($language, $lemmasStr) else () let $dictionariesRemoteTmp := @@ -133,9 +142,21 @@ then + ctp + Chinese Text Project + + linyutan Lin Yutang + + chinese-unicode + Unicode + + + chinese-wiktionary + Wiktionary + else () @@ -165,6 +186,12 @@ then concat("http://nl.wiktionary.org/wiki/", $l) else if ($lexName = "linyutan") then concat("http://humanum.arts.cuhk.edu.hk/cgi-bin/agrep-lindict?query=", $lLink, "&category=wholerecord") + else if ($lexName = "ctp") + then concat("http://ctext.org/dictionary.pl?if=en&char=", $l) + else if ($lexName = "chinese-wiktionary") + then concat("http://en.wiktionary.org/wiki/", $l) + else if ($lexName = "chinese-unicode") + then concat("http://www.unicode.org/cgi-bin/GetUnihanData.pl?codepoint=", $l) else "" let $lexiconEntry := @@ -299,35 +326,35 @@ else () let $dict := - if (not(empty($retDictionaries)) and ($type = "all" or $type = "dict") and $output = "html") + if (not(empty($retDictionaries)) and ($type = "all" or $type = "compact" or $type = "dict") and $output = "html") then

    Dictionary

      {$retDictionaries}

    - else if (empty($retDictionaries) and ($type = "all" or $type = "dict") and $output = "html") + else if (empty($retDictionaries) and ($type = "all" or $type = "compact" or $type = "dict") and $output = "html") then

    Dictionary

      No information available

    - else if (not(empty($retDictionaries)) and ($type = "all" or $type = "dict") and $output = "xml") + else if (not(empty($retDictionaries)) and ($type = "all" or $type = "compact" or $type = "dict") and $output = "xml") then $retDictionaries else () let $morph := - if (not(empty($htmlOrderedLemmas)) and ($type = "all" or $type = "morph") and $output = "html") + if ($language != "zh" and not(empty($htmlOrderedLemmas)) and ($type = "all" or $type = "compact" or $type = "morph") and $output = "html") then

    Morphology

      {$htmlOrderedLemmas}

    - else if (empty($htmlOrderedLemmas) and ($type = "all" or $type = "morph") and $output = "html") + else if ($language != "zh" and empty($htmlOrderedLemmas) and ($type = "all" or $type = "compact" or $type = "morph") and $output = "html") then

    Morphology

      No information available

    - else if (not(empty($htmlOrderedLemmas)) and ($type = "all" or $type = "morph") and $output = "xml") + else if ($language != "zh" and not(empty($htmlOrderedLemmas)) and ($type = "all" or $type = "compact" or $type = "morph") and $output = "xml") then {$xmlOrderedLemmas} else if ($type = "morph" and $output = "string") then $lemmasStrWithoutWord @@ -343,13 +370,13 @@ then {$wikiArticles} else () let $place := - if (not(empty($places)) and ($type = "all" or $type = "place") and $output = "html") + if (not(empty($places)) and ($type = "all" or $type = "compact" or $type = "place") and $output = "html") then

    Place

      {$places}

    - else if (not(empty($places)) and ($type = "all" or $type = "place") and $output = "xml") + else if (not(empty($places)) and ($type = "all" or $type = "compact" or $type = "place") and $output = "xml") then {$places} else () @@ -363,7 +390,7 @@ let $queryResultHeaderStr :=

    Word information for: {$word}

    let $commentExternalLinks := - "[* no guarantee for external links]" + "[* external links may not function]" let $retXmlResult := diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/interface/page-fragment.xql --- a/software/eXist/webapp/mpdl/interface/page-fragment.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/interface/page-fragment.xql Fri Mar 11 13:34:02 2011 +0100 @@ -13,6 +13,7 @@ declare namespace dcterms="http://purl.org/dc/terms"; declare namespace xhtml="http://www.w3.org/1999/xhtml"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; let $mpdlDocUri := request:get-parameter("document", "") let $mode := request:get-parameter("mode", "image") @@ -44,6 +45,8 @@ then $document/archimedes/info else if ($docbase = 'echo') then $document/echo:echo/echo:metadata + else if ($docbase = 'tei') + then $document/TEI:TEI/TEI:teiHeader else '' let $pageBreaks := @@ -51,6 +54,8 @@ then $document//pb else if ($docbase = 'echo') then $document//echo:pb + else if ($docbase = 'tei') + then $document//TEI:pb else $document//pb let $countPagesTemp := count($pageBreaks) let $countPages := @@ -117,6 +122,8 @@ then $metadata/locator else if ($docbase = 'echo') then $metadata/dcterms:identifier + else if ($docbase = 'tei') + then $metadata/TEI:fileDesc/TEI:publicationStmt/TEI:idno else $metadata/dcterms:identifier let $echoDocIdentifier := if ($documentIdentifier != '') @@ -139,6 +146,8 @@ then concat("/permanent/archimedes/", $documentName) else if ($docbase = 'echo') then concat("/permanent/library/", $echoDocIdentifier) + else if ($docbase = 'tei') + then $documentIdentifier else '' let $imagesDocDirectoryIndexMetaUrl := if ($mode = "image" or $mode = "text" or $mode = "textPollux" or $mode = "gis") @@ -158,6 +167,8 @@ let $pageImageFileNameWithoutExtension := if ($docbase = 'echo') then concat("/", string($pb1/@file)) + else if ($docbase = 'tei') + then concat("/", string($pb1/@facs)) else '' let $imageFileName := if ($reqPF = '') @@ -182,6 +193,8 @@ then count($pb1/following::figure[1]/preceding::figure) + 1 else if ($docbase = 'echo') then count($pb1/following::echo:figure[1]/preceding::echo:figure) + 1 + else if ($docbase = 'tei') + then count($pb1/following::TEI:figure[1]/preceding::TEI:figure) + 1 else () let $pageFragmentTmp := diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/interface/queryResult.xql --- a/software/eXist/webapp/mpdl/interface/queryResult.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/interface/queryResult.xql Fri Mar 11 13:34:02 2011 +0100 @@ -6,11 +6,12 @@ declare namespace request="http://exist-db.org/xquery/request"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; + declare namespace dc="http://purl.org/dc/elements/1.1/"; declare namespace dct="http://purl.org/dc/terms/1.0/"; declare namespace rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"; - let $queryType := request:get-parameter("queryType", "") let $docbase := request:get-parameter("docbase", "") let $output := request:get-parameter("output", "html") @@ -41,29 +42,51 @@ let $docBaseArch := "archimedes" let $docBaseEcho := "echo" +let $docBaseTei := "tei" let $fulltextMorphArchDocPath := concat($docPathMorph, "/", $docBaseArch, "/", $language) let $fulltextMorphEchoDocPath := concat($docPathMorph, "/", $docBaseEcho, "/", $language) +let $fulltextMorphTeiDocPath := concat($docPathMorph, "/", $docBaseTei, "/", $language) let $fulltextMorphCollection := - if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho)) + if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphArchDocPath, $fulltextMorphEchoDocPath, $fulltextMorphTeiDocPath) + else if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then collection($fulltextMorphArchDocPath, $fulltextMorphEchoDocPath) - else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho))) + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphArchDocPath, $fulltextMorphTeiDocPath) + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphEchoDocPath, $fulltextMorphTeiDocPath) + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and not(contains($docbase, $docBaseTei))) then collection($fulltextMorphArchDocPath) - else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho)) + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then collection($fulltextMorphEchoDocPath) + else if(not(contains($docbase, $docBaseArch)) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then collection($fulltextMorphTeiDocPath) else () let $fulltextStandardArchDocPath := concat($docPathStandard, "/", $docBaseArch) let $fulltextStandardEchoDocPath := concat($docPathStandard, "/", $docBaseEcho) +let $fulltextStandardTeiDocPath := concat($docPathStandard, "/", $docBaseTei) let $fulltextStandardCollectionStr := - if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho)) + if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardArchDocPath, "', '", $fulltextStandardEchoDocPath, "', '", $fulltextStandardTeiDocPath, "')") + else if(contains($docbase, $docBaseArch) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then concat("collection('", $fulltextStandardArchDocPath, "', '", $fulltextStandardEchoDocPath, "')") - else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho))) + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardArchDocPath, "', '", $fulltextStandardTeiDocPath, "')") + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardEchoDocPath, "', '", $fulltextStandardTeiDocPath, "')") + else if(contains($docbase, $docBaseArch) and not(contains($docbase, $docBaseEcho)) and not(contains($docbase, $docBaseTei))) then concat("collection('", $fulltextStandardArchDocPath, "')") - else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho)) + else if(not(contains($docbase, $docBaseArch)) and contains($docbase, $docBaseEcho) and not(contains($docbase, $docBaseTei))) then concat("collection('", $fulltextStandardEchoDocPath, "')") + else if(not(contains($docbase, $docBaseArch)) and not(contains($docbase, $docBaseEcho)) and contains($docbase, $docBaseTei)) + then concat("collection('", $fulltextStandardTeiDocPath, "')") + else "" +let $metadataStr := concat("(", $fulltextStandardCollectionStr, "/archimedes/info", "|" , $fulltextStandardCollectionStr, "/echo:echo/echo:metadata", "|" , $fulltextStandardCollectionStr, "/TEI:TEI/TEI:teiHeader", ")") +let $fulltextStandardCollection := + if($fulltextStandardCollectionStr != "") + then util:eval($fulltextStandardCollectionStr) else () -let $metadataStr := concat("(", $fulltextStandardCollectionStr, "/archimedes/info", "|" , $fulltextStandardCollectionStr, "/echo:echo/echo:metadata", ")") -let $fulltextStandardCollection := util:eval($fulltextStandardCollectionStr) let $isAttributeSearch := if ($queryType = "attribute") diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/interface/xpath.xql --- a/software/eXist/webapp/mpdl/interface/xpath.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/interface/xpath.xql Fri Mar 11 13:34:02 2011 +0100 @@ -3,6 +3,7 @@ declare namespace request = "http://exist-db.org/xquery/request"; declare namespace util = "http://exist-db.org/xquery/util"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; (: ToDo wenn eine pn gegeben ist, wird momentan der namespace ignoriert :) let $mpdlDocUri := request:get-parameter("document", "") @@ -21,6 +22,8 @@ then $document//pb else if ($docbase = 'echo' and $pn != -1) then $document//echo:pb + else if ($docbase = 'tei') + then $document//TEI:pb else $document//pb let $countPBs := count($pageBreaks) let $pb1 := subsequence($pageBreaks, $pn, 1) diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/interface/xquery.xql --- a/software/eXist/webapp/mpdl/interface/xquery.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/interface/xquery.xql Fri Mar 11 13:34:02 2011 +0100 @@ -3,6 +3,7 @@ declare namespace request = "http://exist-db.org/xquery/request"; declare namespace util = "http://exist-db.org/xquery/util"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; (: ToDo wenn eine pn gegeben ist (also im Fragment untersucht werden soll) geht es momentan nicht s.u. :) (: ToDo wenn eine pn gegeben ist, wird momentan der namespace ignoriert wie z.B. xquery=//echo:s&pn=14 :) @@ -24,6 +25,8 @@ then $document//pb else if ($docbase = 'echo') then $document//echo:pb + else if ($docbase = 'tei') + then $document//TEI:pb else $document//pb let $countPBs := count($pageBreaks) let $pb1 := subsequence($pageBreaks, $pn, 1) diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/lucene/search.xql --- a/software/eXist/webapp/mpdl/lucene/search.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/lucene/search.xql Fri Mar 11 13:34:02 2011 +0100 @@ -7,6 +7,7 @@ declare namespace ft = "http://exist-db.org/xquery/lucene"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; declare namespace dc="http://purl.org/dc/elements/1.1/"; declare namespace dcterms="http://purl.org/dc/terms"; @@ -15,7 +16,7 @@ let $luceneParseResult := mpdltext:lucene-parse-query($queryStr) let $result := if ($luceneParseResult = '') - then $mpdlCollection/.[ft:query(archimedes/text, $queryStr) or ft:query(echo:echo/echo:text, $queryStr)] + then $mpdlCollection/.[ft:query(archimedes/text, $queryStr) or ft:query(echo:echo/echo:text, $queryStr) or ft:query(TEI:TEI/TEI:text, $queryStr)] else {$luceneParseResult} @@ -41,6 +42,8 @@ then $document//pb else if ($mpdlCollectionName = 'echo') then $document//echo:pb + else if ($mpdlCollectionName = 'tei') + then $document//TEI:pb else $document//pb let $luceneParseResult := mpdltext:lucene-parse-query($queryStr) let $t := @@ -50,6 +53,8 @@ then $document//s[ft:query(., $query)] else if ($mpdlCollectionName = 'echo') then $document//echo:s[ft:query(., $query)] + else if ($mpdlCollectionName = 'tei') + then $document//TEI:s[ft:query(., $query)] else $document//s[ft:query(., $query)] let $from := ($pn * $pageSize) - $pageSize + 1 let $to := $pn * $pageSize @@ -73,6 +78,8 @@ then count($pb/following::s[. << $s]) + 1 else if ($mpdlCollectionName = 'echo') then count($pb/following::echo:s[. << $s]) + 1 + else if ($mpdlCollectionName = 'tei') + then count($pb/following::TEI:s[. << $s]) + 1 else count($pb/following::s[. << $s]) + 1 let $position := $from - 1 + $pos let $resultElem := @@ -202,6 +209,8 @@ then $doc/archimedes/info else if ($docBase = 'echo') then $doc/echo:echo/echo:metadata + else if ($docBase = 'tei') + then $doc/TEI:TEI/TEI:teiHeader else () return $result }; @@ -212,6 +221,8 @@ then $doc/archimedes/text else if ($docBase = 'echo') then $doc/echo:echo/echo:text + else if ($docBase = 'tei') + then $doc/TEI:TEI/TEI:text else () return $result }; @@ -230,6 +241,7 @@ declare function mpdl-lucene:getAttrQueryStr($attribute, $attrValue) { let $attrArch := mpdl-lucene:getElemNameByAttr("archimedes", $attribute) let $attrEcho := mpdl-lucene:getElemNameByAttr("echo", $attribute) + let $attrTei := mpdl-lucene:getElemNameByAttr("tei", $attribute) let $attrArchRelQueryStr := if ($attribute = "date") then concat($attrArch, " = '", $attrValue, "'") @@ -238,13 +250,25 @@ if ($attribute = "date") then concat($attrEcho, " = '", $attrValue, "'") else concat("ft:query(", $attrEcho, ", '", $attrValue, "')") + let $attrTeiRelQueryStr := + if ($attribute = "date") + then concat($attrTei, " = '", $attrValue, "'") + else concat("ft:query(", $attrTei, ", '", $attrValue, "')") let $result := - if ($attrArch != "" and $attrEcho != "") + if ($attrArch != "" and $attrEcho != "" and $attrTei != "") + then concat($attrArchRelQueryStr, " or ", $attrEchoRelQueryStr, " or ", $attrTeiRelQueryStr) + else if ($attrArch != "" and $attrEcho != "" and $attrTei = "") then concat($attrArchRelQueryStr, " or ", $attrEchoRelQueryStr) - else if ($attrArch = "" and $attrEcho != "") + else if ($attrArch != "" and $attrEcho = "" and $attrTei != "") + then concat($attrArchRelQueryStr, " or ", $attrTeiRelQueryStr) + else if ($attrArch = "" and $attrEcho != "" and $attrTei != "") + then concat($attrEchoRelQueryStr, " or ", $attrTeiRelQueryStr) + else if ($attrArch != "" and $attrEcho = "" and $attrTei = "") + then $attrArchRelQueryStr + else if ($attrArch = "" and $attrEcho != "" and $attrTei = "") then $attrEchoRelQueryStr - else if ($attrArch != "" and $attrEcho = "") - then $attrArchRelQueryStr + else if ($attrArch = "" and $attrEcho = "" and $attrTei != "") + then $attrTeiRelQueryStr else "" return $result }; @@ -252,55 +276,80 @@ declare function mpdl-lucene:getElemNameByAttr($docBase, $attribute) { let $docBaseArch := "archimedes" let $docBaseEcho := "echo" + let $docBaseTei := "tei" let $result := if ($docBase = $docBaseArch and $attribute = "author") then "author" else if ($docBase = $docBaseEcho and $attribute = "author") then "dcterms:creator" + else if ($docBase = $docBaseTei and $attribute = "author") + then "TEI:fileDesc/TEI:titleStmt/TEI:author" else if ($docBase = $docBaseArch and $attribute = "title") then "title" else if ($docBase = $docBaseEcho and $attribute = "title") then "dcterms:title" + else if ($docBase = $docBaseTei and $attribute = "title") + then "TEI:fileDesc/TEI:titleStmt/TEI:title" else if ($docBase = $docBaseArch and $attribute = "place") then "place" else if ($docBase = $docBaseEcho and $attribute = "place") then "" + else if ($docBase = $docBaseTei and $attribute = "place") + then "TEI:fileDesc/TEI:publicationStmt/TEI:pubPlace" else if ($docBase = $docBaseArch and $attribute = "date") then "date" else if ($docBase = $docBaseEcho and $attribute = "date") then "dcterms:date" + else if ($docBase = $docBaseTei and $attribute = "date") + then "TEI:fileDesc/TEI:publicationStmt/TEI:date" else if ($docBase = $docBaseArch and $attribute = "language") then "lang" else if ($docBase = $docBaseEcho and $attribute = "language") then "dcterms:language" + else if ($docBase = $docBaseTei and $attribute = "language") + then "TEI:profileDesc/TEI:langUsage/TEI:language/@ident" else if ($docBase = $docBaseArch and $attribute = "identifier") then "locator" else if ($docBase = $docBaseEcho and $attribute = "identifier") then "dcterms:identifier" + else if ($docBase = $docBaseTei and $attribute = "identifier") + then "identifier" else if ($docBase = $docBaseArch and $attribute = "rights") then "" else if ($docBase = $docBaseEcho and $attribute = "rights") then "dcterms:rights" + else if ($docBase = $docBaseTei and $attribute = "rights") + then "rights" else if ($docBase = $docBaseArch and $attribute = "license") then "" else if ($docBase = $docBaseEcho and $attribute = "license") then "dcterms:license" + else if ($docBase = $docBaseTei and $attribute = "license") + then "" else if ($docBase = $docBaseArch and $attribute = "accessRights") then "" else if ($docBase = $docBaseEcho and $attribute = "accessRights") then "dcterms:accessRights" + else if ($docBase = $docBaseTei and $attribute = "accessRights") + then "accessRights" else if ($docBase = $docBaseArch and $attribute = "file") then "cvs_file" else if ($docBase = $docBaseEcho and $attribute = "file") then "" + else if ($docBase = $docBaseTei and $attribute = "file") + then "" else if ($docBase = $docBaseArch and $attribute = "translator") then "translator" else if ($docBase = $docBaseEcho and $attribute = "translator") then "" + else if ($docBase = $docBaseTei and $attribute = "translator") + then "" else if ($docBase = $docBaseArch and $attribute = "version") then "cvs_version" else if ($docBase = $docBaseEcho and $attribute = "version") then "" + else if ($docBase = $docBaseTei and $attribute = "version") + then "" else "" return $result @@ -309,6 +358,7 @@ declare function mpdl-lucene:getElementsByAttr($metadata, $docBase, $attribute) { let $docBaseArch := "archimedes" let $docBaseEcho := "echo" + let $docBaseTei := "tei" let $result := if ($docBase = $docBaseArch and $attribute = "author") then @@ -318,6 +368,10 @@ then for $elem in $metadata/dcterms:creator return {$elem} + else if ($docBase = $docBaseTei and $attribute = "author") + then + for $elem in $metadata/TEI:fileDesc/TEI:titleStmt/TEI:author + return {$elem} else if ($docBase = $docBaseArch and $attribute = "title") then for $elem in $metadata/title @@ -326,6 +380,10 @@ then for $elem in $metadata/dcterms:title return {$elem} + else if ($docBase = $docBaseTei and $attribute = "title") + then + for $elem in $metadata/TEI:fileDesc/TEI:titleStmt/TEI:title + return {$elem} else if ($docBase = $docBaseArch and $attribute = "place") then for $elem in $metadata/place @@ -340,10 +398,16 @@ then for $elem in $metadata/dcterms:date return {$elem} + else if ($docBase = $docBaseTei and $attribute = "date") + then + for $elem in $metadata/TEI:fileDesc/TEI:publicationStmt/TEI:date + return {$elem} else if ($docBase = $docBaseArch and $attribute = "language") then $metadata/lang else if ($docBase = $docBaseEcho and $attribute = "language") then $metadata/dcterms:language + else if ($docBase = $docBaseTei and $attribute = "language") + then $metadata/TEI:profileDesc/TEI:langUsage/TEI:language/@ident else if ($docBase = $docBaseArch and $attribute = "identifier") then $metadata/locator else if ($docBase = $docBaseEcho and $attribute = "identifier") @@ -354,12 +418,16 @@ then for $elem in $metadata/dcterms:rights return {$elem} + else if ($docBase = $docBaseTei and $attribute = "rights") + then $metadata/TEI:fileDesc/TEI:publicationStmt/TEI:availability else if ($docBase = $docBaseArch and $attribute = "accessRights") then () else if ($docBase = $docBaseEcho and $attribute = "accessRights") then for $elem in $metadata/dcterms:accessRights return {$elem} + else if ($docBase = $docBaseTei and $attribute = "accessRights") + then $metadata/TEI:fileDesc/TEI:publicationStmt/TEI:availability/@status else if ($docBase = $docBaseArch and $attribute = "license") then () else if ($docBase = $docBaseEcho and $attribute = "license") diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/page-query-result.xql --- a/software/eXist/webapp/mpdl/page-query-result.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/page-query-result.xql Fri Mar 11 13:34:02 2011 +0100 @@ -13,6 +13,7 @@ declare namespace dcterms="http://purl.org/dc/terms"; declare namespace xhtml="http://www.w3.org/1999/xhtml"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; let $mpdlDocUri := request:get-parameter("document", "") let $queryType := request:get-parameter("query-type", "") @@ -54,6 +55,8 @@ then $document/archimedes/info else if ($docbase = 'echo') then $document/echo:echo/echo:metadata + else if ($docbase = 'tei') + then $document/TEI:TEI/TEI:teiHeader else '' let $pageBreaks := @@ -61,6 +64,8 @@ then $document//pb else if ($docbase = 'echo') then $document//echo:pb + else if ($docbase = 'tei') + then $document//TEI:pb else $document//pb let $countPagesTemp := count($pageBreaks) let $countPages := @@ -69,7 +74,7 @@ else 1 (: xQuery inline execution does not work in module so it has to be done here :) -let $xQueryPageSize := 100 +let $xQueryPageSize := 1000 let $xQueryResultEval := if ($queryType = 'xpath' or $queryType = 'xquery' and $query != "") then util:eval-inline($document, $query) @@ -159,6 +164,8 @@ then $metadata/locator else if ($docbase = 'echo') then $metadata/dcterms:identifier + else if ($docbase = 'tei') + then $metadata/TEI:fileDesc/TEI:publicationStmt/TEI:idno else $metadata/dcterms:identifier let $echoDocIdentifier := if ($documentIdentifier != '') @@ -181,6 +188,8 @@ then concat("/permanent/archimedes/", $documentName) else if ($docbase = 'echo') then concat("/permanent/library/", $echoDocIdentifier) + else if ($docbase = 'tei') + then $documentIdentifier else '' let $imagesDocDirectoryIndexMetaUrl := if ($mode = "image" or $mode = "text" or $mode = "textPollux" or $mode = "gis") @@ -200,6 +209,8 @@ let $pageImageFileNameWithoutExtension := if ($docbase = 'echo') then concat("/", string($pb1/@file)) + else if ($docbase = 'tei') + then concat("/", string($pb1/@facs)) else '' let $imageFileName := if ($reqPF = '') @@ -224,6 +235,8 @@ then count($pb1/following::figure[1]/preceding::figure) + 1 else if ($docbase = 'echo') then count($pb1/following::echo:figure[1]/preceding::echo:figure) + 1 + else if ($docbase = 'tei') + then count($pb1/following::TEI:figure[1]/preceding::TEI:figure) + 1 else () let $pageFragmentTmp := @@ -411,7 +424,7 @@ if ($errorCode < 10 and $reqExport = "pdf") then mpdl-text:html2pdf($language, $xmlResult, $xslFilePath, $titleStr, $pn, $mode) else if ($errorCode < 10 and not($reqExport = "pdf")) - then mpdl-text:transform($xmlResult, $xslFilePath) + then mpdl-text:transform($xmlResult, $xslFilePath) else
    {$xmlResult}
    (: error xml result :) let $result := diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/presentation/functions-mpdl.xsl --- a/software/eXist/webapp/mpdl/presentation/functions-mpdl.xsl Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/presentation/functions-mpdl.xsl Fri Mar 11 13:34:02 2011 +0100 @@ -72,12 +72,12 @@
    -
    +

    - - + +
    diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/presentation/pageFragmentHtml.xsl --- a/software/eXist/webapp/mpdl/presentation/pageFragmentHtml.xsl Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/presentation/pageFragmentHtml.xsl Fri Mar 11 13:34:02 2011 +0100 @@ -11,7 +11,8 @@ xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms" xmlns:echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/" - xmlns:mml="http://www.w3.org/1998/Math/MathML" + xmlns:m="http://www.w3.org/1998/Math/MathML" + xmlns:svg="http://www.w3.org/2000/svg" xmlns:xhtml="http://www.w3.org/1999/xhtml"> @@ -224,32 +225,45 @@ - + + +
    -
    + + +
    +
    + +
    + -

    - - - - - - - - - - - - - - - -

    + + +

    + + + + + + + + + + + + + + + +

    +
    + +
    @@ -290,18 +304,153 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + + + + - + - + + + +
    - + + + + + + + + + + + + + - - - - - - - - - - - - - - -
    Operation
    Destination
    + Document base: + {$docBaseSelectBoxDest} + Language: + {$languageSelectBoxDest} +

    Document name: Info document interface source
    Document link:

    Source Info document interface source
    Local file: +
    or
    Url:

    + Operation

    Source Info document interface source
    Local file: -
    or
    Url:

    Destination
    Document base: - {$docBaseSelectBoxDest} -
    Language: - {$languageSelectBoxDest} -
    Document name: Info document interface source
    Document link:
    + + + + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -367,11 +516,12 @@ - + + @@ -389,7 +539,27 @@

    - + + + + + + + + + + + + + + + + + + + + +
    @@ -421,21 +591,6 @@ - - - - - - - - - - - - - - - @@ -453,7 +608,7 @@ -
    +
    @@ -518,9 +673,24 @@ - - - + + + + + + + + + + + + + + + + + + @@ -567,13 +737,20 @@ - + + + + + + + + - + @@ -609,11 +786,6 @@ - - - - - @@ -637,6 +809,7 @@ + @@ -644,6 +817,7 @@ + diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/presentation/pageHtml.css --- a/software/eXist/webapp/mpdl/presentation/pageHtml.css Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/presentation/pageHtml.css Fri Mar 11 13:34:02 2011 +0100 @@ -34,6 +34,14 @@ margin-right: 10px; padding-top: 1px; } +span.dc-unmodified { + float: left; + font-family: Georgia; + font-size: 250%; + line-height: 0.8em; + margin-right: 10px; + padding-top: 1px; +} /* variables and numbers */ span.var { font-style:italic; } @@ -56,27 +64,30 @@ /* indentation at the beginning of a paragraph: */ span.sc { font-weight:bold; } span.sc.it {font-weight:bold; font-style:italic; } - -/* regularized words */ -span.reg { color:purple; } /* ref */ span.ref { font-style:italic; } /* quotes */ -div.q { margin-left:10px; font-style:italic; } +span.q { font-style:italic; } div.quote { margin-left:10px; font-style:italic; } div.blockquote { margin-left:10px; font-style:normal; } div.set-off { margin-left:10px; font-style:italic; } +/* terminology */ +span.term { color:purple; } /* Blue */ + /* notes */ span.note { font-style:italic; } +span.note.margin.left { position:absolute; left:2em; font-style:normal; } +span.note.margin.right { position:absolute; left:30em; font-style:normal; } /* GIS elements */ -span.place { background-color:#87F717; color:black; } /* Lawn green */ -span.person { background-color:#87F717; color:black; } /* Lawn green */ -span.time { background-color:#87F717; color:black; } /* Lawn green */ -span.event { background-color:#87F717; color:black; } /* Lawn green */ +span.place { color:#0000FF; } /* Blue */ +span.person { color:#0000FF; } /* Blue */ +span.organization { color:#0000FF; } /* Blue */ +span.time { color:#0000FF; } /* Blue */ +span.event { color:#0000FF; } /* Blue */ /* preliminary representations of single/double/wavy/circled lines in Chinese text */ span.sl { text-decoration:underline; } /* DESpecs for Chinese: */ diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/presentation/pageHtml.xsl --- a/software/eXist/webapp/mpdl/presentation/pageHtml.xsl Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/presentation/pageHtml.xsl Fri Mar 11 13:34:02 2011 +0100 @@ -11,7 +11,8 @@ xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms" xmlns:echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/" - xmlns:mml="http://www.w3.org/1998/Math/MathML" + xmlns:m="http://www.w3.org/1998/Math/MathML" + xmlns:svg="http://www.w3.org/2000/svg" xmlns:xhtml="http://www.w3.org/1999/xhtml"> @@ -750,32 +751,45 @@ - + + +
    -
    + + +
    +
    + +
    + -

    - - - - - - - - - - - - - - - -

    + + +

    + + + + + + + + + + + + + + + +

    +
    + +
    @@ -816,18 +830,153 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + + + + - + - + + + + + + + + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -893,11 +1042,12 @@ - + + @@ -915,7 +1065,27 @@

    - + + + + + + + + + + + + + + + + + + + + +
    @@ -947,21 +1117,6 @@
    - - - - - - - - - - - - - - - @@ -979,7 +1134,7 @@ -
    +
    @@ -1044,9 +1199,24 @@ - - - + + + + + + + + + + + + + + + + + + @@ -1092,13 +1262,20 @@ - + + + + + + + + - + @@ -1134,11 +1311,6 @@ - - - - - @@ -1162,6 +1334,7 @@ + @@ -1169,6 +1342,7 @@ + @@ -1194,7 +1368,6 @@ - diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/query.xql --- a/software/eXist/webapp/mpdl/query.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/query.xql Fri Mar 11 13:34:02 2011 +0100 @@ -89,6 +89,13 @@ + + TEI Schema
    + (since 2011) + + + + Info Document bases @@ -235,7 +242,7 @@

    See the eXist XQuery documentation and the XQuery source of this page, if you find a bug let us know -
    Last MPDL software update: January, 2011 +
    Last MPDL software update: March, 2011 \ No newline at end of file diff -r 59ff47d1e237 -r d6f528ad5d96 software/eXist/webapp/mpdl/text/all.xql --- a/software/eXist/webapp/mpdl/text/all.xql Fri Mar 11 13:33:26 2011 +0100 +++ b/software/eXist/webapp/mpdl/text/all.xql Fri Mar 11 13:34:02 2011 +0100 @@ -9,6 +9,8 @@ declare namespace local = "http://www.mpiwg-berlin.mpg.de/ns/mpdl/local"; declare namespace echo="http://www.mpiwg-berlin.mpg.de/ns/echo/1.0/"; +declare namespace TEI="http://www.tei-c.org/ns/1.0"; + declare namespace dcterms="http://purl.org/dc/terms"; declare function mpdl-text:insertNodeIdAttribute($element as element()) { @@ -41,6 +43,8 @@ then $document/archimedes/text else if ($mpdlCollectionName = 'echo') then $document/echo:echo/echo:text + else if ($mpdlCollectionName = 'tei') + then $document/TEI:TEI/TEI:text else $document/archimedes/text let $from := ($pn * $pageSize) - $pageSize + 1 let $to := $pn * $pageSize @@ -131,16 +135,22 @@ then $document//echo:figure else if ($docBase = 'archimedes' and $queryType = 'figures') then $document//figure + else if ($docBase = 'tei' and $queryType = 'figures') + then $document//TEI:figure else () let $tocEntriesAllTmp := for $entry at $pos in $tocEntriesAll let $pb := if ($docBase = 'echo') then $entry/preceding::echo:pb[1] + else if ($docBase = 'tei') + then $entry/preceding::TEI:pb[1] else $entry/preceding::pb[1] let $pageNum := if ($docBase = 'echo') then count($pb/preceding::echo:pb) + 1 + else if ($docBase = 'tei') + then count($pb/preceding::TEI:pb) + 1 else count($pb/preceding::pb) + 1 let $level := if ($queryType = 'toc') @@ -206,12 +216,16 @@ then $document/archimedes/info else if ($docbase = 'echo') then $document/echo:echo/echo:metadata + else if ($docbase = 'tei') + then $document/TEI:TEI/TEI:teiHeader else '' let $documentIdentifier := if ($docbase = 'archimedes') then $metadata/locator else if ($docbase = 'echo') then $metadata/dcterms:identifier + else if ($docbase = 'tei') + then $metadata/TEI:fileDesc/TEI:publicationStmt/TEI:idno else $metadata/dcterms:identifier let $echoDocIdentifier := if ($documentIdentifier != '') @@ -231,6 +245,8 @@ then concat("/permanent/archimedes/", $documentName) else if ($docbase = 'echo') then concat("/permanent/library/", $echoDocIdentifier) + else if ($docbase = 'tei') + then $documentIdentifier else '' let $imagesDocDirectoryIndexMetaUrl := concat($nausikaaURLTexter, "?fn=", $imagesDocDirectory, "/index.meta") let $digilibAvailable := mpdldoc:check-uri($imagesDocDirectoryIndexMetaUrl, 2000)