org.carrot2.text.preprocessing.filter
Interface ILabelFilter

All Known Implementing Classes:
CompleteLabelFilter, GenitiveLabelFilter, MinLengthLabelFilter, NumericLabelFilter, QueryLabelFilter, SingleLabelFilterBase, StopLabelFilter, StopWordLabelFilter

public interface ILabelFilter

Defines the contract for label filtering components, which mark words and phrases that should not be considered as candidates for cluster labels

See Also:
LabelFilterProcessor

Method Summary
 void filter(PreprocessingContext context, boolean[] acceptedStems, boolean[] acceptedPhrases)
          Called to perform label filtering.
 boolean isEnabled()
           
 

Method Detail

filter

void filter(PreprocessingContext context,
            boolean[] acceptedStems,
            boolean[] acceptedPhrases)
Called to perform label filtering.

Parameters:
context - contains words and phrases to be filtered
acceptedStems - the filter should set to false those elements that correspond to the stems to be filtered out
acceptedPhrases - the filter should set to false those elements that correspond to the phrases to be filtered out

isEnabled

boolean isEnabled()
Returns:
true if the filter is to be applied, false if the filter should be omitted by the LabelFilterProcessor.


Copyright (c) Dawid Weiss, Stanislaw Osinski