1 | static VirtualNodeIndex hugeEnglishDictionary_virtualNodeIndex() {
|
2 | ret new HugeEnglishDictionary_VirtualNodeIndex; |
3 | } |
4 | |
5 | sclass HugeEnglishDictionary_VirtualNodeIndex extends VirtualNodeIndex {
|
6 | SortedCondensedStrings2 dict = hugeEnglishDictionary(); |
7 | |
8 | *() {
|
9 | addAll(implicitConcepts, "is", "an english word according to the huge dictionary"); |
10 | } |
11 | |
12 | int numWebs() { ret l(dict); }
|
13 | int numTerms() { ret l(dict); }
|
14 | |
15 | Collection<S> indexedTerms() { ret dict; }
|
16 | |
17 | L<WebNode> get(CharSequence _query) {
|
18 | S query = str(_query); |
19 | query = lower(query); |
20 | if (!dict.contains(query)) ret emptyList(); |
21 | ret ll(web_firstNode(webFromTriple(query, "is", "an english word according to the huge dictionary"))); |
22 | } |
23 | |
24 | bool hasShortTerm(S s) { ret dict.contains(lower(s)); }
|
25 | } |
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1011467 |
| Snippet name: | hugeEnglishDictionary_virtualNodeIndex |
| Eternal ID of this version: | #1011467/14 |
| Text MD5: | 9e6cbae93caad87c671bac3528ce3dfd |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2017-12-13 01:44:11 |
| Source code size: | 815 bytes / 25 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 697 / 723 |
| Version history: | 13 change(s) |
| Referenced in: | [show references] |