|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.nutch.analysis.NutchAnalysis
The JavaCC-generated Nutch lexical analyzer and query parser.
Field Summary | |
org.apache.nutch.analysis.Token |
jj_nt
|
boolean |
lookingAhead
|
org.apache.nutch.analysis.Token |
token
|
NutchAnalysisTokenManager |
token_source
|
Fields inherited from interface org.apache.nutch.analysis.NutchAnalysisConstants |
ACRONYM, APOSTROPHE, ATSIGN, C_PLUS_PLUS, C_SHARP, CJK, COLON, DEFAULT, DIGIT, DOT, EOF, IRREGULAR_WORD, LETTER, MINUS, PLUS, QUOTE, SIGRAM, SLASH, tokenImage, WHITE, WORD, WORD_PUNCT |
Constructor Summary | |
NutchAnalysis(org.apache.nutch.analysis.CharStream stream)
|
|
NutchAnalysis(NutchAnalysisTokenManager tm)
|
Method Summary | |
ArrayList |
compound(String field)
Parse a compound term that is interpreted as an implicit phrase query. |
void |
disable_tracing()
|
void |
enable_tracing()
|
org.apache.nutch.analysis.ParseException |
generateParseException()
|
org.apache.nutch.analysis.Token |
getNextToken()
|
org.apache.nutch.analysis.Token |
getToken(int index)
|
void |
infix()
Characters which can be used to form compound terms. |
static boolean |
isStopWord(String word)
True iff word is a stop word. |
static void |
main(String[] args)
For debugging. |
void |
nonOpInfix()
Parse infix characters except plus and minus. |
void |
nonOpOrTerm()
Parse anything but a term or an operator (plur or minus or quote). |
void |
nonTerm()
Parse anything but a term or a quote. |
void |
nonTermOrEOF()
|
Query |
parse()
Parse a query. |
static Query |
parseQuery(String queryString)
Construct a query parser for the text in a reader. |
ArrayList |
phrase(String field)
Parse an explcitly quoted phrase query. |
void |
ReInit(org.apache.nutch.analysis.CharStream stream)
|
void |
ReInit(NutchAnalysisTokenManager tm)
|
String |
term()
Parse a single term. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public NutchAnalysisTokenManager token_source
public org.apache.nutch.analysis.Token token
public org.apache.nutch.analysis.Token jj_nt
public boolean lookingAhead
Constructor Detail |
public NutchAnalysis(org.apache.nutch.analysis.CharStream stream)
public NutchAnalysis(NutchAnalysisTokenManager tm)
Method Detail |
public static boolean isStopWord(String word)
public static Query parseQuery(String queryString) throws IOException
IOException
public static void main(String[] args) throws Exception
Exception
public final Query parse() throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final ArrayList phrase(String field) throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final ArrayList compound(String field) throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final String term() throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final void nonTerm() throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final void nonTermOrEOF() throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final void nonOpOrTerm() throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final void infix() throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public final void nonOpInfix() throws org.apache.nutch.analysis.ParseException
org.apache.nutch.analysis.ParseException
public void ReInit(org.apache.nutch.analysis.CharStream stream)
public void ReInit(NutchAnalysisTokenManager tm)
public final org.apache.nutch.analysis.Token getNextToken()
public final org.apache.nutch.analysis.Token getToken(int index)
public org.apache.nutch.analysis.ParseException generateParseException()
public final void enable_tracing()
public final void disable_tracing()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |