queryparser.html

来自「 Lucene是apache软件基金会[4] jakarta项目组的一个子项目」· HTML 代码 · 共 1,243 行 · 第 1/5 页

HTML
1,243
字号
 <A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#getWildcardQuery(java.lang.String, java.lang.String)"><CODE>getWildcardQuery(java.lang.String, java.lang.String)</CODE></A>).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../org/apache/lucene/search/Query.html" title="class in org.apache.lucene.search">Query</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#getRangeQuery(java.lang.String, java.lang.String, java.lang.String, boolean)">getRangeQuery</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;field,              <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;part1,              <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;part2,              boolean&nbsp;inclusive)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../org/apache/lucene/queryParser/Token.html" title="class in org.apache.lucene.queryParser">Token</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#getToken(int)">getToken</A></B>(int&nbsp;index)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#getUseOldRangeQuery()">getUseOldRangeQuery</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../org/apache/lucene/search/Query.html" title="class in org.apache.lucene.search">Query</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#getWildcardQuery(java.lang.String, java.lang.String)">getWildcardQuery</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;field,                 <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;termStr)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Factory method for generating a query.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#main(java.lang.String[])">main</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>[]&nbsp;args)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Command line tool to test QueryParser, using <A HREF="../../../../org/apache/lucene/analysis/SimpleAnalyzer.html" title="class in org.apache.lucene.analysis"><CODE>SimpleAnalyzer</CODE></A>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#Modifiers()">Modifiers</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../org/apache/lucene/search/Query.html" title="class in org.apache.lucene.search">Query</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#parse(java.lang.String)">parse</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;query)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses a query string, returning a <A HREF="../../../../org/apache/lucene/search/Query.html" title="class in org.apache.lucene.search"><CODE>Query</CODE></A>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../org/apache/lucene/search/Query.html" title="class in org.apache.lucene.search">Query</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#Query(java.lang.String)">Query</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;field)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#ReInit(org.apache.lucene.queryParser.CharStream)">ReInit</A></B>(<A HREF="../../../../org/apache/lucene/queryParser/CharStream.html" title="interface in org.apache.lucene.queryParser">CharStream</A>&nbsp;stream)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#ReInit(org.apache.lucene.queryParser.QueryParserTokenManager)">ReInit</A></B>(<A HREF="../../../../org/apache/lucene/queryParser/QueryParserTokenManager.html" title="class in org.apache.lucene.queryParser">QueryParserTokenManager</A>&nbsp;tm)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setAllowLeadingWildcard(boolean)">setAllowLeadingWildcard</A></B>(boolean&nbsp;allowLeadingWildcard)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Set to <code>true</code> to allow <code>*</code> and <code>?</code> as the first character  of a PrefixQuery and WildcardQuery.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setDateResolution(org.apache.lucene.document.DateTools.Resolution)">setDateResolution</A></B>(<A HREF="../../../../org/apache/lucene/document/DateTools.Resolution.html" title="class in org.apache.lucene.document">DateTools.Resolution</A>&nbsp;dateResolution)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the default date resolution used by RangeQueries for fields for which no specific date resolutions has been set.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setDateResolution(java.lang.String, org.apache.lucene.document.DateTools.Resolution)">setDateResolution</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;fieldName,                  <A HREF="../../../../org/apache/lucene/document/DateTools.Resolution.html" title="class in org.apache.lucene.document">DateTools.Resolution</A>&nbsp;dateResolution)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the date resolution used by RangeQueries for a specific field.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setDefaultOperator(org.apache.lucene.queryParser.QueryParser.Operator)">setDefaultOperator</A></B>(<A HREF="../../../../org/apache/lucene/queryParser/QueryParser.Operator.html" title="class in org.apache.lucene.queryParser">QueryParser.Operator</A>&nbsp;op)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the boolean operator of the QueryParser.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setFuzzyMinSim(float)">setFuzzyMinSim</A></B>(float&nbsp;fuzzyMinSim)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Set the minimum similarity for fuzzy queries.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setFuzzyPrefixLength(int)">setFuzzyPrefixLength</A></B>(int&nbsp;fuzzyPrefixLength)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Set the prefix length for fuzzy queries.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setLocale(java.util.Locale)">setLocale</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Locale.html" title="class or interface in java.util">Locale</A>&nbsp;locale)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Set locale used by date range parsing.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setLowercaseExpandedTerms(boolean)">setLowercaseExpandedTerms</A></B>(boolean&nbsp;lowercaseExpandedTerms)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Whether terms of wildcard, prefix, fuzzy and range queries are to be automatically lower-cased or not.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setPhraseSlop(int)">setPhraseSlop</A></B>(int&nbsp;phraseSlop)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the default slop for phrases.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#setUseOldRangeQuery(boolean)">setUseOldRangeQuery</A></B>(boolean&nbsp;useOldRangeQuery)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;By default QueryParser uses new ConstantScoreRangeQuery in preference to RangeQuery for range queries.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../org/apache/lucene/search/Query.html" title="class in org.apache.lucene.search">Query</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/lucene/queryParser/QueryParser.html#Term(java.lang.String)">Term</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;field)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ FIELD DETAIL =========== -->

<A NAME="field_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Field Detail</B></FONT></TD>
</TR>
</TABLE>

<A NAME="AND_OPERATOR"><!-- --></A><H3>
AND_OPERATOR</H3>
<PRE>
public static final <A HREF="../../../../org/apache/lucene/queryParser/QueryParser.Operator.html" title="class in org.apache.lucene.queryParser">QueryParser.Operator</A> <B>AND_OPERATOR</B></PRE>
<DL>
<DD>Alternative form of QueryParser.Operator.AND
<P>
<DL>
</DL>
</DL>
<HR>

<A NAME="OR_OPERATOR"><!-- --></A><H3>
OR_OPERATOR</H3>
<PRE>
public static final <A HREF="../../../../org/apache/lucene/queryParser/QueryParser.Operator.html" title="class in org.apache.lucene.queryParser">QueryParser.Operator</A> <B>OR_OPERATOR</B></PRE>
<DL>
<DD>Alternative form of QueryParser.Operator.OR
<P>
<DL>
</DL>
</DL>
<HR>

<A NAME="token_source"><!-- --></A><H3>
token_source</H3>
<PRE>
public <A HREF="../../../../org/apache/lucene/queryParser/QueryParserTokenManager.html" title="class in org.apache.lucene.queryParser">QueryParserTokenManager</A> <B>token_source</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>

<A NAME="token"><!-- --></A><H3>
token</H3>
<PRE>
public <A HREF="../../../../org/apache/lucene/queryParser/Token.html" title="class in org.apache.lucene.queryParser">Token</A> <B>token</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>

<A NAME="jj_nt"><!-- --></A><H3>
jj_nt</H3>
<PRE>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?