|
Carrot2 v3.5.2
API Documentation |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.carrot2.text.preprocessing.filter.SingleLabelFilterBase
org.carrot2.text.preprocessing.filter.StopWordLabelFilter
public class StopWordLabelFilter
Accepts words that are not stop words and phrases that do not start nor end in a stop word.
| Field Summary | |
|---|---|
boolean |
enabled
Remove leading and trailing stop words. |
| Constructor Summary | |
|---|---|
StopWordLabelFilter()
|
|
| Method Summary | |
|---|---|
boolean |
acceptPhrase(PreprocessingContext context,
int phraseIndex)
Should return true if the phrase located at phraseIndex
is to be accepted, false otherwise. |
boolean |
acceptWord(PreprocessingContext context,
int wordIndex)
Should return true if the word located at wordIndex is to
be accepted, false otherwise. |
boolean |
isEnabled()
|
| Methods inherited from class org.carrot2.text.preprocessing.filter.SingleLabelFilterBase |
|---|
filter |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public boolean enabled
| Constructor Detail |
|---|
public StopWordLabelFilter()
| Method Detail |
|---|
public boolean acceptPhrase(PreprocessingContext context,
int phraseIndex)
SingleLabelFilterBasetrue if the phrase located at phraseIndex
is to be accepted, false otherwise.
acceptPhrase in class SingleLabelFilterBasecontext - provides access to all information about the phrasephraseIndex - index of the phrase for which decision is to be made
public boolean acceptWord(PreprocessingContext context,
int wordIndex)
SingleLabelFilterBasetrue if the word located at wordIndex is to
be accepted, false otherwise.
acceptWord in class SingleLabelFilterBasecontext - provides access to all information about the wordwordIndex - index of the word for which decision is to be madepublic boolean isEnabled()
true if the filter is to be applied, false if the
filter should be omitted by the LabelFilterProcessor.
|
Please refer to project documentation at
http://project.carrot2.org |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||