Class Highlighter
Class used to markup highlighted terms found in the best sections of a
text, using configurable IFragmenter,
Inheritance
Assembly: Lucene.Net.Highlighter.dll
Syntax
public class Highlighter : object
Constructors
Name | Description |
---|---|
Highlighter(IFormatter, IEncoder, IScorer) | |
Highlighter(IFormatter, IScorer) | |
Highlighter(IScorer) |
Fields
Name | Description |
---|---|
DEFAULT_MAX_CHARS_TO_ANALYZE |
Properties
Name | Description |
---|---|
Encoder | |
FragmentScorer | |
MaxDocCharsToAnalyze | |
TextFragmenter |
Methods
Name | Description |
---|---|
GetBestFragment(Analyzer, String, String) | Highlights chosen terms in a text, extracting the most relevant section. This is a convenience method that calls GetBestFragment(TokenStream, String) |
GetBestFragment(TokenStream, String) | Highlights chosen terms in a text, extracting the most relevant section. The document text is analysed in chunks to record hit statistics across the document. After accumulating stats, the fragment with the highest score is returned |
GetBestFragments(Analyzer, String, String, Int32) | Highlights chosen terms in a text, extracting the most relevant sections. This is a convenience method that calls GetBestFragments(TokenStream, String, Int32) |
GetBestFragments(TokenStream, String, Int32) | Highlights chosen terms in a text, extracting the most relevant sections. The document text is analysed in chunks to record hit statistics across the document. After accumulating stats, the fragments with the highest scores are returned as an array of strings in order of score (contiguous fragments are merged into one in their original order to improve readability) |
GetBestFragments(TokenStream, String, Int32, String) | Highlights terms in the |
GetBestTextFragments(TokenStream, String, Boolean, Int32) | Low level api to get the most relevant (formatted) sections of the document. This method has been made public to allow visibility of score information held in TextFragment objects. Thanks to Jason Calabrese for help in redefining the interface. |