Can someone suggest me a better way to get hits (not occurrences) of a word on a document in Lucene? ..
Lucene uses an index rather than a document-based index. To get the number of terms per document:
SpanTermQuery.getSpans . , , , .
Source: https://habr.com/ru/post/1783952/More articles:Using manifest in standalone HTML5 in IFrame - html5How to use I use Zend_Cache_Backend_TwoLevels with tags? - phpRuby and Sinatra - ruby | fooobar.comHow to view the contents of cacerts.bks (certificate file / system / etc / security / carcerts.bks) - androidGetting the number of hits in a document (doc) in lucene - javaMount or collage with GD library - phpКакова математика для эстетики пользовательского интерфейса, например цветовая гармония? - color-schemeBig O: Which is better? - big-oPHP: __callStatic alternative for 5.2.x - phpIronPython error related to long boolean expressions? - ironpythonAll Articles