⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 analyzer.html

📁  Lucene是apache软件基金会[4] jakarta项目组的一个子项目
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/IndexWriter.html#IndexWriter(org.apache.lucene.store.Directory, org.apache.lucene.analysis.Analyzer, boolean)">IndexWriter</A></B>(<A HREF="../../../../../org/apache/lucene/store/Directory.html" title="class in org.apache.lucene.store">Directory</A>&nbsp;d,            <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;a,            boolean&nbsp;create)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs an IndexWriter for the index in <code>d</code>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/IndexWriter.html#IndexWriter(java.lang.String, org.apache.lucene.analysis.Analyzer)">IndexWriter</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;path,            <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;a)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs an IndexWriter for the index in <code>path</code>, creating it first if it does not already exist, otherwise appending to the existing index.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/IndexWriter.html#IndexWriter(java.io.File, org.apache.lucene.analysis.Analyzer)">IndexWriter</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/File.html" title="class or interface in java.io">File</A>&nbsp;path,            <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;a)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs an IndexWriter for the index in <code>path</code>, creating it first if it does not already exist, otherwise appending to the existing index.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/IndexWriter.html#IndexWriter(org.apache.lucene.store.Directory, org.apache.lucene.analysis.Analyzer)">IndexWriter</A></B>(<A HREF="../../../../../org/apache/lucene/store/Directory.html" title="class in org.apache.lucene.store">Directory</A>&nbsp;d,            <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;a)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs an IndexWriter for the index in <code>d</code>, creating it first if it does not already exist, otherwise appending to the existing index.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/IndexModifier.html#IndexModifier(org.apache.lucene.store.Directory, org.apache.lucene.analysis.Analyzer, boolean)">IndexModifier</A></B>(<A HREF="../../../../../org/apache/lucene/store/Directory.html" title="class in org.apache.lucene.store">Directory</A>&nbsp;directory,              <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;analyzer,              boolean&nbsp;create)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Open an index with write access.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/IndexModifier.html#IndexModifier(java.lang.String, org.apache.lucene.analysis.Analyzer, boolean)">IndexModifier</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;dirName,              <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;analyzer,              boolean&nbsp;create)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Open an index with write access.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/IndexModifier.html#IndexModifier(java.io.File, org.apache.lucene.analysis.Analyzer, boolean)">IndexModifier</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/File.html" title="class or interface in java.io">File</A>&nbsp;file,              <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;analyzer,              boolean&nbsp;create)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Open an index with write access.</TD>
</TR>
</TABLE>
&nbsp;
<P>
<A NAME="org.apache.lucene.index.memory"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
Uses of <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A> in <A HREF="../../../../../org/apache/lucene/index/memory/package-summary.html">org.apache.lucene.index.memory</A></FONT></TD>
</TR>
</TABLE>
&nbsp;
<P>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
<TD COLSPAN=2>Subclasses of <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A> in <A HREF="../../../../../org/apache/lucene/index/memory/package-summary.html">org.apache.lucene.index.memory</A></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;class</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/lucene/index/memory/PatternAnalyzer.html" title="class in org.apache.lucene.index.memory">PatternAnalyzer</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Efficient Lucene analyzer/tokenizer that preferably operates on a String rather than a <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/Reader.html" title="class or interface in java.io"><CODE>Reader</CODE></A>, that can flexibly separate text into terms via a regular expression <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/regex/Pattern.html" title="class or interface in java.util.regex"><CODE>Pattern</CODE></A> (with behaviour identical to <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html#split(java.lang.String)" title="class or interface in java.lang"><CODE>String.split(String)</CODE></A>), and that combines the functionality of <A HREF="../../../../../org/apache/lucene/analysis/LetterTokenizer.html" title="class in org.apache.lucene.analysis"><CODE>LetterTokenizer</CODE></A>, <A HREF="../../../../../org/apache/lucene/analysis/LowerCaseTokenizer.html" title="class in org.apache.lucene.analysis"><CODE>LowerCaseTokenizer</CODE></A>, <A HREF="../../../../../org/apache/lucene/analysis/WhitespaceTokenizer.html" title="class in org.apache.lucene.analysis"><CODE>WhitespaceTokenizer</CODE></A>, <A HREF="../../../../../org/apache/lucene/analysis/StopFilter.html" title="class in org.apache.lucene.analysis"><CODE>StopFilter</CODE></A> into a single efficient multi-purpose class.</TD>
</TR>
</TABLE>
&nbsp;
<P>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
<TD COLSPAN=2>Methods in <A HREF="../../../../../org/apache/lucene/index/memory/package-summary.html">org.apache.lucene.index.memory</A> that return <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></CODE></FONT></TD>
<TD><CODE><B>AnalyzerUtil.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/AnalyzerUtil.html#getLoggingAnalyzer(org.apache.lucene.analysis.Analyzer, java.io.PrintStream, java.lang.String)">getLoggingAnalyzer</A></B>(<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;child,                   <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/PrintStream.html" title="class or interface in java.io">PrintStream</A>&nbsp;log,                   <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;logName)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a simple analyzer wrapper that logs all tokens produced by the underlying child analyzer to the given log stream (typically System.err); Otherwise behaves exactly like the child analyzer, delivering the very same tokens; useful for debugging purposes on custom indexing and/or querying.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></CODE></FONT></TD>
<TD><CODE><B>AnalyzerUtil.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/AnalyzerUtil.html#getMaxTokenAnalyzer(org.apache.lucene.analysis.Analyzer, int)">getMaxTokenAnalyzer</A></B>(<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;child,                    int&nbsp;maxTokens)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an analyzer wrapper that returns at most the first <code>maxTokens</code> tokens from the underlying child analyzer, ignoring all remaining tokens.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></CODE></FONT></TD>
<TD><CODE><B>AnalyzerUtil.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/AnalyzerUtil.html#getPorterStemmerAnalyzer(org.apache.lucene.analysis.Analyzer)">getPorterStemmerAnalyzer</A></B>(<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;child)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an English stemming analyzer that stems tokens from the underlying child analyzer according to the Porter stemming algorithm.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></CODE></FONT></TD>
<TD><CODE><B>AnalyzerUtil.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/AnalyzerUtil.html#getSynonymAnalyzer(org.apache.lucene.analysis.Analyzer, org.apache.lucene.index.memory.SynonymMap, int)">getSynonymAnalyzer</A></B>(<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;child,                   <A HREF="../../../../../org/apache/lucene/index/memory/SynonymMap.html" title="class in org.apache.lucene.index.memory">SynonymMap</A>&nbsp;synonyms,                   int&nbsp;maxSynonyms)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an analyzer wrapper that wraps the underlying child analyzer's token stream into a <A HREF="../../../../../org/apache/lucene/index/memory/SynonymTokenFilter.html" title="class in org.apache.lucene.index.memory"><CODE>SynonymTokenFilter</CODE></A>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></CODE></FONT></TD>
<TD><CODE><B>AnalyzerUtil.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/AnalyzerUtil.html#getTokenCachingAnalyzer(org.apache.lucene.analysis.Analyzer)">getTokenCachingAnalyzer</A></B>(<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;child)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an analyzer wrapper that caches all tokens generated by the underlying child analyzer's token streams, and delivers those cached tokens on subsequent calls to  <code>tokenStream(String fieldName, Reader reader)</code>  if the fieldName has been seen before, altogether ignoring the Reader parameter on cache lookup.</TD>
</TR>
</TABLE>
&nbsp;
<P>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
<TD COLSPAN=2>Methods in <A HREF="../../../../../org/apache/lucene/index/memory/package-summary.html">org.apache.lucene.index.memory</A> with parameters of type <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></FONT></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>MemoryIndex.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/MemoryIndex.html#addField(java.lang.String, java.lang.String, org.apache.lucene.analysis.Analyzer)">addField</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="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;text,         <A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;analyzer)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method; Tokenizes the given field text and adds the resulting terms to the index; Equivalent to adding an indexed non-keyword Lucene <A HREF="../../../../../org/apache/lucene/document/Field.html" title="class in org.apache.lucene.document"><CODE>Field</CODE></A> that is <A HREF="../../../../../org/apache/lucene/document/Field.Index.html#TOKENIZED"><CODE>tokenized</CODE></A>, <A HREF="../../../../../org/apache/lucene/document/Field.Store.html#NO"><CODE>not stored</CODE></A>, <A HREF="../../../../../org/apache/lucene/document/Field.TermVector.html#WITH_POSITIONS"><CODE>termVectorStored with positions</CODE></A> (or <A HREF="../../../../../org/apache/lucene/document/Field.TermVector.html#WITH_POSITIONS"><CODE>termVectorStored with positions and offsets</CODE></A>),</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></CODE></FONT></TD>
<TD><CODE><B>AnalyzerUtil.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/AnalyzerUtil.html#getLoggingAnalyzer(org.apache.lucene.analysis.Analyzer, java.io.PrintStream, java.lang.String)">getLoggingAnalyzer</A></B>(<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A>&nbsp;child,                   <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/PrintStream.html" title="class or interface in java.io">PrintStream</A>&nbsp;log,                   <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;logName)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a simple analyzer wrapper that logs all tokens produced by the underlying child analyzer to the given log stream (typically System.err); Otherwise behaves exactly like the child analyzer, delivering the very same tokens; useful for debugging purposes on custom indexing and/or querying.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.html" title="class in org.apache.lucene.analysis">Analyzer</A></CODE></FONT></TD>
<TD><CODE><B>AnalyzerUtil.</B><B><A HREF="../../../../../org/apache/lucene/index/memory/AnalyzerUtil.html#getMaxTokenAnalyzer(org.apache.lucene.analysis.Analyzer, int)">getMaxTokenAnalyzer</A></B>(<A HREF="../../../../../org/apache/lucene/analysis/Analyzer.h

⌨️ 快捷键说明

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