C# Class Lucene.Net.Analysis.En.PorterStemmer

Stemmer, implementing the Porter Stemming Algorithm The Stemmer class transforms a word into its root form. The input word can be provided a character at time (by calling add()), or at once by calling one of the various stem(something) methods.
Afficher le fichier Open project: apache/lucenenet

Méthodes publiques

Méthode Description
Add ( char ch ) : void

Add a character to the word being stemmed. When you are finished adding characters, you can call stem(void) to process the word.

PorterStemmer ( ) : Lucene.Net.Util
Reset ( ) : void

reset() resets the stemmer so it can stem another word. If you invoke the stemmer by calling add(char) and then stem(), you must call reset() before starting another word.

Stem ( ) : bool

Stem the word placed into the Stemmer buffer through calls to add(). Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().

Stem ( char word ) : bool

Stem a word contained in a char[]. Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().

Stem ( char word, int wordLen ) : bool

Stem a word contained in a leading portion of a char[] array. Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().

Stem ( char wordBuffer, int offset, int wordLen ) : bool

Stem a word contained in a portion of a char[] array. Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().

Stem ( int i0 ) : bool
Stem ( string s ) : string

Stem a word provided as a String. Returns the result as a String.

ToString ( ) : string

After a word has been stemmed, it can be retrieved by toString(), or a reference to the internal buffer can be retrieved by getResultBuffer and getResultLength (which is generally more efficient.)

Private Methods

Méthode Description
Cons ( int i ) : bool
Cvc ( int i ) : bool
DoubleC ( int j ) : bool
Ends ( string s ) : bool
M ( ) : int
SetTo ( string s ) : void
Step1 ( ) : void
Step2 ( ) : void
Step3 ( ) : void
Step4 ( ) : void
Step5 ( ) : void
Step6 ( ) : void
VowelInStem ( ) : bool
r ( string s ) : void

Method Details

Add() public méthode

Add a character to the word being stemmed. When you are finished adding characters, you can call stem(void) to process the word.
public Add ( char ch ) : void
ch char
Résultat void

PorterStemmer() public méthode

public PorterStemmer ( ) : Lucene.Net.Util
Résultat Lucene.Net.Util

Reset() public méthode

reset() resets the stemmer so it can stem another word. If you invoke the stemmer by calling add(char) and then stem(), you must call reset() before starting another word.
public Reset ( ) : void
Résultat void

Stem() public méthode

Stem the word placed into the Stemmer buffer through calls to add(). Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().
public Stem ( ) : bool
Résultat bool

Stem() public méthode

Stem a word contained in a char[]. Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().
public Stem ( char word ) : bool
word char
Résultat bool

Stem() public méthode

Stem a word contained in a leading portion of a char[] array. Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().
public Stem ( char word, int wordLen ) : bool
word char
wordLen int
Résultat bool

Stem() public méthode

Stem a word contained in a portion of a char[] array. Returns true if the stemming process resulted in a word different from the input. You can retrieve the result with getResultLength()/getResultBuffer() or toString().
public Stem ( char wordBuffer, int offset, int wordLen ) : bool
wordBuffer char
offset int
wordLen int
Résultat bool

Stem() public méthode

public Stem ( int i0 ) : bool
i0 int
Résultat bool

Stem() public méthode

Stem a word provided as a String. Returns the result as a String.
public Stem ( string s ) : string
s string
Résultat string

ToString() public méthode

After a word has been stemmed, it can be retrieved by toString(), or a reference to the internal buffer can be retrieved by getResultBuffer and getResultLength (which is generally more efficient.)
public ToString ( ) : string
Résultat string