Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F97217845
api.xql
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Jan 3, 13:17
Size
1 KB
Mime Type
text/x-java
Expires
Sun, Jan 5, 13:17 (2 d)
Engine
blob
Format
Raw Data
Handle
23356892
Attached To
rNIETZSCHEDM nietzsche-dm
api.xql
View Options
xquery version "3.1";
declare namespace api="https://tei-publisher.com/xquery/api";
declare namespace output="http://www.w3.org/2010/xslt-xquery-serialization";
declare namespace tei="http://www.tei-c.org/ns/1.0";
import module namespace roaster="http://e-editiones.org/roaster";
import module namespace auth="http://e-editiones.org/roaster/auth";
import module namespace rutil="http://e-editiones.org/roaster/util";
import module namespace dapi="http://teipublisher.com/api/documents" at "api/document.xql";
import module namespace capi="http://teipublisher.com/api/collection" at "api/collection.xql";
import module namespace sapi="http://teipublisher.com/api/search" at "api/search.xql";
import module namespace deploy="http://teipublisher.com/api/generate" at "api/generate.xql";
import module namespace dts="http://teipublisher.com/api/dts" at "api/dts.xql";
import module namespace iapi="http://teipublisher.com/api/info" at "api/info.xql";
import module namespace vapi="http://teipublisher.com/api/view" at "api/view.xql";
import module namespace anno="http://teipublisher.com/api/annotations" at "api/annotations.xql";
import module namespace custom="http://teipublisher.com/api/custom" at "../custom-api.xql";
import module namespace nlp="http://teipublisher.com/api/nlp" at "api/nlp.xql";
import module namespace console="http://exist-db.org/xquery/console";
declare option output:indent "no";
let $lookup := function($name as xs:string) {
try {
let $cfun := custom:lookup($name, 1)
return
if (empty($cfun)) then
function-lookup(xs:QName($name), 1)
else
$cfun
} catch * {
()
}
}
let $resp := roaster:route(("modules/custom-api.json", "modules/lib/api.json"), $lookup)
return
$resp
Event Timeline
Log In to Comment