Indexing Searcher
The Indexing Searcher is the object used for free-text or exact periods searches over the added documents with the Indexing Writer. This version is backed by the Apache Lucene.
Version 3.x
Basic Usage
1
2
3
4
5
6
7
8
| var writer = require('indexing/v3/writer');
var searcher = require('indexing/v3/searcher');
writer.add("index2", "file1", "apache lucene", new Date(123));
writer.add("index2", "file2", "lucene - the search engine", new Date(234), {"name2":"value2"});
writer.add("index2", "file3", "search engine", new Date(345), {"name2":"value2"});
var found = searcher.between("index2", new Date(124), new Date(344));
|
Definition
Functions
Function |
Description |
Returns |
search(index, term) |
Returns an array of document descriptors matching the term |
list of descriptors |
before(index, date) |
Returns an array of document descriptors where lastModified is before the date |
list of descriptors |
after(index, date) |
Returns an array of document descriptors where lastModified is after the date |
list of descriptors |
between(index, lower, upper) |
Returns an array of document descriptors where lastModified is between the lower and upper |
list of descriptors |
Compatibility
Rhino |
Nashorn |
V8 |
β
|
β
|
β
|
Edit