blob: 600d858a70cd284623ba84a6f0a342fd08bbba63 [file] [log] [blame]
<html dir="LTR">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252" />
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5" />
<title>IndexWriter Constructor (String, Analyzer, Boolean)</title>
<xml>
</xml>
<link rel="stylesheet" type="text/css" href="MSDN.css" />
</head>
<body id="bodyID" class="dtBODY">
<div id="nsbanner">
<div id="bannerrow1">
<table class="bannerparthead" cellspacing="0">
<tr id="hdr">
<td class="runninghead">Apache Lucene.Net 2.4.0 Class Library API</td>
<td class="product">
</td>
</tr>
</table>
</div>
<div id="TitleRow">
<h1 class="dtH1">IndexWriter Constructor (String, Analyzer, Boolean)</h1>
</div>
</div>
<div id="nstext">
<P>
<FONT color="red">
<B>NOTE: This constructor is now obsolete.</B>
</FONT>
</P>
<P>
<B>This constructor will be removed in the 3.0 release. Use IndexWriter(string, Analyzer, bool, MaxFieldLength) instead, and call Commit() when needed</B>
</P>
<HR /> Constructs an IndexWriter for the index in <pre class="code">path</pre>. Text will be analyzed with <pre class="code">a</pre>. If <pre class="code">create</pre> is true, then a new, empty index will be created in <pre class="code">path</pre>, replacing the index already there, if any. <p>Throws CorruptIndexException if the index is corrupt</p>
<p>Throws LockObtainFailedException if another writer has this index open (<pre class="code">write.lock</pre> could not be obtained)</p>
<p>Throws System.IO.IOException if the directory cannot be read/written to, or if it does not exist and <pre class="code">create</pre> is <pre class="code">false</pre> or if there is any other low-level IO error</p>
<div class="syntax">public IndexWriter(<br />   <a href="ms-help://MS.NETFrameworkSDKv1.1/cpref/html/frlrfSystemStringClassTopic.htm">string</a> <i>path</i>,<br />   <a href="Lucene.Net.Analysis.Analyzer.html">Analyzer</a> <i>a</i>,<br />   <a href="ms-help://MS.NETFrameworkSDKv1.1/cpref/html/frlrfSystemBooleanClassTopic.htm">bool</a> <i>create</i><br />);</div><h4 class="dtH4">Parameters</h4><dl><dt><i>path</i></dt><dd>the path to the index directory</dd><dt><i>a</i></dt><dd>the analyzer to use</dd><dt><i>create</i></dt><dd><pre class="code">true</pre> to create the index or overwrite the existing one; <pre class="code">false</pre> to append to the existing index</dd></dl><h4 class="dtH4">See Also</h4><p><a href="Lucene.Net.Index.IndexWriter.html">IndexWriter Class</a> | <a href="Lucene.Net.Index.html">Lucene.Net.Index Namespace</a> | <a href="Lucene.Net.Index.IndexWriterConstructor.html">IndexWriter Constructor Overload List</a></p><hr /><div id="footer"><p></p><p>Generated from assembly Lucene.Net [2.4.0.2]</p></div></div>
</body>
</html>