static L dm_gazelle_fullSearch(S query, O... _) { Set<S> types = cast optPar types(_); int maxResults = optPar maxResults(_, 1000); L<S> prepared = scoredSearch_prepare(query); new Map<O, Int> scores; if (emptyOrContains(types, 'rule)) scoredSearchInAllStringFields_impl(prepared, scores, (L) dm_call(dm_gazelle_rulesModule(), 'concepts)); if (emptyOrContains(types, 'line)) scoredSearchInAllStringFields_impl(prepared, scores, (L) dm_call(dm_gazelle_linesCRUD(), 'concepts)); ret takeFirst(maxResults, keysSortedByValuesDesc(scores)); }
download show line numbers debug dex old transpilations
Travelled to 8 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, whxojlpjdney
No comments. add comment
Snippet ID: | #1021913 |
Snippet name: | dm_gazelle_fullSearch - try to search everywhere |
Eternal ID of this version: | #1021913/12 |
Text MD5: | 2132fc22e88ade5af529e077ab282514 |
Author: | stefan |
Category: | javax / discord |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-03-04 21:40:42 |
Source code size: | 603 bytes / 16 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 283 / 337 |
Version history: | 11 change(s) |
Referenced in: | [show references] |