precedencequeryparser.html

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

HTML
1,161
字号
</DL>

<!-- ============ METHOD DETAIL ========== -->

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

<A NAME="parse(java.lang.String)"><!-- --></A><H3>
parse</H3>
<PRE>
public <A HREF="../../../../../org/apache/lucene/search/Query.html" title="class in org.apache.lucene.search">Query</A> <B>parse</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;expression)            throws <A HREF="../../../../../org/apache/lucene/queryParser/precedence/ParseException.html" title="class in org.apache.lucene.queryParser.precedence">ParseException</A></PRE>
<DL>
<DD>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>.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>expression</CODE> - the query string to be parsed.<DT><B>Throws:</B><DD><CODE><A HREF="../../../../../org/apache/lucene/queryParser/precedence/ParseException.html" title="class in org.apache.lucene.queryParser.precedence">ParseException</A></CODE> - if the parsing fails</DL>
</DD>
</DL>
<HR>

<A NAME="getAnalyzer()"><!-- --></A><H3>
getAnalyzer</H3>
<PRE>
public <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A> <B>getAnalyzer</B>()</PRE>
<DL>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>Returns the analyzer.</DL>
</DD>
</DL>
<HR>

<A NAME="getField()"><!-- --></A><H3>
getField</H3>
<PRE>
public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> <B>getField</B>()</PRE>
<DL>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>Returns the field.</DL>
</DD>
</DL>
<HR>

<A NAME="getFuzzyMinSim()"><!-- --></A><H3>
getFuzzyMinSim</H3>
<PRE>
public float <B>getFuzzyMinSim</B>()</PRE>
<DL>
<DD>Get the minimal similarity for fuzzy queries.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="setFuzzyMinSim(float)"><!-- --></A><H3>
setFuzzyMinSim</H3>
<PRE>
public void <B>setFuzzyMinSim</B>(float&nbsp;fuzzyMinSim)</PRE>
<DL>
<DD>Set the minimum similarity for fuzzy queries. Default is 0.5f.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="getFuzzyPrefixLength()"><!-- --></A><H3>
getFuzzyPrefixLength</H3>
<PRE>
public int <B>getFuzzyPrefixLength</B>()</PRE>
<DL>
<DD>Get the prefix length for fuzzy queries.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>Returns the fuzzyPrefixLength.</DL>
</DD>
</DL>
<HR>

<A NAME="setFuzzyPrefixLength(int)"><!-- --></A><H3>
setFuzzyPrefixLength</H3>
<PRE>
public void <B>setFuzzyPrefixLength</B>(int&nbsp;fuzzyPrefixLength)</PRE>
<DL>
<DD>Set the prefix length for fuzzy queries. Default is 0.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>fuzzyPrefixLength</CODE> - The fuzzyPrefixLength to set.</DL>
</DD>
</DL>
<HR>

<A NAME="setPhraseSlop(int)"><!-- --></A><H3>
setPhraseSlop</H3>
<PRE>
public void <B>setPhraseSlop</B>(int&nbsp;phraseSlop)</PRE>
<DL>
<DD>Sets the default slop for phrases.  If zero, then exact phrase matches are required.  Default value is zero.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="getPhraseSlop()"><!-- --></A><H3>
getPhraseSlop</H3>
<PRE>
public int <B>getPhraseSlop</B>()</PRE>
<DL>
<DD>Gets the default slop for phrases.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="setDefaultOperator(org.apache.lucene.queryParser.precedence.PrecedenceQueryParser.Operator)"><!-- --></A><H3>
setDefaultOperator</H3>
<PRE>
public void <B>setDefaultOperator</B>(org.apache.lucene.queryParser.precedence.PrecedenceQueryParser.Operator&nbsp;op)</PRE>
<DL>
<DD>Sets the boolean operator of the QueryParser. In default mode (<code>OR_OPERATOR</code>) terms without any modifiers are considered optional: for example <code>capital of Hungary</code> is equal to <code>capital OR of OR Hungary</code>.<br/> In <code>AND_OPERATOR</code> mode terms are considered to be in conjuction: the above mentioned query is parsed as <code>capital AND of AND Hungary</code>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="getDefaultOperator()"><!-- --></A><H3>
getDefaultOperator</H3>
<PRE>
public org.apache.lucene.queryParser.precedence.PrecedenceQueryParser.Operator <B>getDefaultOperator</B>()</PRE>
<DL>
<DD>Gets implicit operator setting, which will be either AND_OPERATOR or OR_OPERATOR.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="setLowercaseExpandedTerms(boolean)"><!-- --></A><H3>
setLowercaseExpandedTerms</H3>
<PRE>
public void <B>setLowercaseExpandedTerms</B>(boolean&nbsp;lowercaseExpandedTerms)</PRE>
<DL>
<DD>Whether terms of wildcard, prefix, fuzzy and range queries are to be automatically lower-cased or not.  Default is <code>true</code>.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="getLowercaseExpandedTerms()"><!-- --></A><H3>
getLowercaseExpandedTerms</H3>
<PRE>
public boolean <B>getLowercaseExpandedTerms</B>()</PRE>
<DL>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>See Also:</B><DD><A HREF="../../../../../org/apache/lucene/queryParser/precedence/PrecedenceQueryParser.html#setLowercaseExpandedTerms(boolean)"><CODE>setLowercaseExpandedTerms(boolean)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="setLocale(java.util.Locale)"><!-- --></A><H3>
setLocale</H3>
<PRE>
public void <B>setLocale</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)</PRE>

⌨️ 快捷键说明

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