-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathllt.segtok_to_tb.js
62 lines (61 loc) · 1.6 KB
/
llt.segtok_to_tb.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
(function (factory) {
if (typeof define === 'function' && define.amd) {
// AMD. Register as an anonymous module.
define(['cts'], factory);
} else {
factory(CTS);
}
}(function(CTS) {
/**
* LLT Segtok(enization) service's output into a Treebank Annotation
*
* @Github : https://github.com/alpheios-project/treebank-editor/blob/master/db/xslt/segtok_to_tb.xsl
*
*/
CTS.xslt.stylesheets["llt.segtok_to_tb"] = function(endpoint, options) {
CTS.xslt.XSLT.call(this, endpoint, options);
this.options = {
"e_lang" : {
"type" : "string",
"html" : "input",
"default" : "lat"
},
"e_format" : {
"type" : "string",
"html" : "input",
"default" : "aldt"
},
"e_docuri" : {
"type" : "string",
"html" : "input",
"default" : ""
},
"e_agenturi" : {
"type" : "string",
"html" : "input",
"default" : "http://services.perseids.org/llt/segtok"
},
"e_appuri" : {
"type" : "string",
"html" : "input",
"default" : ""
},
"e_datetime" : {
"type" : "string",
"html" : "hidden",
"default" : function() { return (new Date()).toDateString(); }
},
"e_collection" : {
"type" : "string",
"html" : "input",
"default" : "urn:cite:perseus:lattb"
},
"e_attachtoroot" : {
"type" : "boolean",
"html" : "checkbox",
"default" : false
}
}
}
CTS.xslt.stylesheets["llt.segtok_to_tb"].prototype = Object.create(CTS.xslt.XSLT)
}));