public class SentenceLengthFilter extends FilterMapper<String>
| Constructor and Description |
|---|
SentenceLengthFilter(int minWords,
int maxWords)
Constructs a new
SentenceLengthFilter object. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
doFilter(String sent) |
static SentenceLengthFilter |
maxFilter(int maxWords)
Constructs a new
SentenceLengthFilter object, with no minimum length. |
static SentenceLengthFilter |
minFilter(int minWords)
Constructs a new
SentenceLengthFilter object, with no maximum length. |
doMappublic SentenceLengthFilter(int minWords,
int maxWords)
SentenceLengthFilter object.minWords - the minimum number of words in the sentence.maxWords - the maximum number of words in the sentence.public static SentenceLengthFilter minFilter(int minWords)
SentenceLengthFilter object, with no maximum length.minWords - the minimum number of words.SentenceLengthFilter.public static SentenceLengthFilter maxFilter(int maxWords)
SentenceLengthFilter object, with no minimum length.maxWords - the maximum number of words.SentenceLengthFilter.public boolean doFilter(String sent)
doFilter in class FilterMapper<String>Copyright © 2010-2013 University of Washington CSE. All Rights Reserved.