Token filter that removes stop words. These words must be provided as array (set), example: $stopwords = array('the' => 1, 'an' => '1');
We do recommend to provide all words in lowercase and concatenate this class after the lowercase filter.
category | Zend |
---|---|
package | Zend_Search_Lucene |
subpackage | Analysis |
copyright | Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com) |
license | New BSD License |
inherited_from | \Zend_Search_Lucene_Analysis_TokenFilter |
__construct(array $stopwords = array()
)
array
array (set) of words that will be filtered out
loadFromFile(string $filepath = null
)
You can call this method one or more times. New stopwords are always added to current set.
string
full path for text file with stopwords
\Zend_Search_Exception |
When the file doesn`t exists or is not readable. |
---|
normalize(\Zend_Search_Lucene_Analysis_Token $srcToken) : \Zend_Search_Lucene_Analysis_Token
inherited_from | \Zend_Search_Lucene_Analysis_TokenFilter::normalize() |
---|
\Zend_Search_Lucene_Analysis_Token
\Zend_Search_Lucene_Analysis_Token
normalize(\Zend_Search_Lucene_Analysis_Token $srcToken) : \Zend_Search_Lucene_Analysis_Token
\Zend_Search_Lucene_Analysis_Token
\Zend_Search_Lucene_Analysis_Token
$_stopSet : array