|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.lucene.util.AttributeSource org.apache.lucene.analysis.TokenStream org.apache.lucene.analysis.TokenFilter com.atlassian.jira.issue.index.analyzer.WildcardFilter
public class WildcardFilter
This Filter adds wildcards to the tokens returned by standard filters.
It can be difficult to do wild card search over a stemmed index - for example 'feature' will be stemmed to feature and if you search for 'feature*' you will not match 'feature'. To search for 'feature*' then stem first and then wildcard. The need for this was highlighted by (JRA-19918) This filter stems and then appends the wildcard to each existing token, so it makes no sense for it not to be the final filter in the chain. note that the query returned will actually not work (it will look for the litral * as it is a term query - use the query to get the text and then search)
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.apache.lucene.util.AttributeSource |
---|
org.apache.lucene.util.AttributeSource.AttributeFactory, org.apache.lucene.util.AttributeSource.State |
Field Summary | |
---|---|
static char |
WILDCARD_OPERATOR
Wildcrad character: U+002A (ASTERISK) |
Fields inherited from class org.apache.lucene.analysis.TokenFilter |
---|
input |
Constructor Summary | |
---|---|
WildcardFilter(org.apache.lucene.analysis.TokenStream in)
|
Method Summary | |
---|---|
boolean |
incrementToken()
|
Methods inherited from class org.apache.lucene.analysis.TokenFilter |
---|
close, end, reset |
Methods inherited from class org.apache.lucene.util.AttributeSource |
---|
addAttribute, addAttributeImpl, captureState, clearAttributes, cloneAttributes, copyTo, equals, getAttribute, getAttributeClassesIterator, getAttributeFactory, getAttributeImplsIterator, hasAttribute, hasAttributes, hashCode, reflectAsString, reflectWith, restoreState, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final char WILDCARD_OPERATOR
Constructor Detail |
---|
public WildcardFilter(org.apache.lucene.analysis.TokenStream in)
Method Detail |
---|
public final boolean incrementToken() throws IOException
incrementToken
in class org.apache.lucene.analysis.TokenStream
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |