Class ThaiAnalyzer
Lucene.Net.Analysis.Analyzer for Thai language. It uses ICU4N.Text.BreakIterator to break words.
You must specify the required Lucene.Net.Util.LuceneVersion compatibility when creating ThaiAnalyzer:
- As of 3.6, a set of Thai stopwords is used by default
Implements
Inherited Members
Namespace: Lucene.Net.Analysis.Th
Assembly: Lucene.Net.ICU.dll
Syntax
public sealed class ThaiAnalyzer : StopwordAnalyzerBase, IDisposable
Constructors
ThaiAnalyzer(LuceneVersion)
Builds an analyzer with the default stop words.
Declaration
public ThaiAnalyzer(LuceneVersion matchVersion)
Parameters
Type | Name | Description |
---|---|---|
LuceneVersion | matchVersion | lucene compatibility version |
ThaiAnalyzer(LuceneVersion, CharArraySet)
Builds an analyzer with the given stop words.
Declaration
public ThaiAnalyzer(LuceneVersion matchVersion, CharArraySet stopwords)
Parameters
Type | Name | Description |
---|---|---|
LuceneVersion | matchVersion | lucene compatibility version |
CharArraySet | stopwords | a stopword set |
Fields
DEFAULT_STOPWORD_FILE
File containing default Thai stopwords.
Declaration
public const string DEFAULT_STOPWORD_FILE = "stopwords.txt"
Field Value
Type | Description |
---|---|
string |
Properties
DefaultStopSet
Returns an unmodifiable instance of the default stop words set.
Declaration
public static CharArraySet DefaultStopSet { get; }
Property Value
Type | Description |
---|---|
CharArraySet | default stop words set. |
Methods
CreateComponents(string, TextReader)
Creates Lucene.Net.Analysis.TokenStreamComponents used to tokenize all the text in the provided TextReader.
Declaration
protected override TokenStreamComponents CreateComponents(string fieldName, TextReader reader)
Parameters
Type | Name | Description |
---|---|---|
string | fieldName | |
TextReader | reader |
Returns
Type | Description |
---|---|
TokenStreamComponents | Lucene.Net.Analysis.TokenStreamComponents built from a Lucene.Net.Analysis.Standard.StandardTokenizer filtered with Lucene.Net.Analysis.Standard.StandardFilter, Lucene.Net.Analysis.Core.LowerCaseFilter, ThaiWordFilter, and Lucene.Net.Analysis.Core.StopFilter |