You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-commits@lucene.apache.org by dn...@apache.org on 2005/05/24 20:53:22 UTC
svn commit: r178245 - in /lucene/java/trunk/src: java/overview.html
test/org/apache/lucene/TestDemo.java
Author: dnaber
Date: Tue May 24 11:53:21 2005
New Revision: 178245
URL: http://svn.apache.org/viewcvs?rev=178245&view=rev
Log:
adding setMaxFieldLength() to the example; Jakarta -> Apache
Modified:
lucene/java/trunk/src/java/overview.html
lucene/java/trunk/src/test/org/apache/lucene/TestDemo.java
Modified: lucene/java/trunk/src/java/overview.html
URL: http://svn.apache.org/viewcvs/lucene/java/trunk/src/java/overview.html?rev=178245&r1=178244&r2=178245&view=diff
==============================================================================
--- lucene/java/trunk/src/java/overview.html (original)
+++ lucene/java/trunk/src/java/overview.html Tue May 24 11:53:21 2005
@@ -1,10 +1,10 @@
<html>
<head>
- <title>Jakarta Lucene API</title>
+ <title>Apache Lucene API</title>
</head>
<body>
-<p>Jakarta Lucene is a high-performance, full-featured text search engine library.
+<p>Apache Lucene is a high-performance, full-featured text search engine library.
Here's a simple example how to use Lucene for indexing and searching (using JUnit
to check if the results are what we expect):</p>
@@ -27,6 +27,7 @@
<font color="#ffffff"> </font><font color="#3f7f5f">// if one exists):</font><br/>
<font color="#ffffff"> </font><font color="#3f7f5f">//Directory directory = FSDirectory.getDirectory("/tmp/testindex", true);</font><br/>
<font color="#ffffff"> </font><font color="#000000">IndexWriter iwriter = </font><font color="#7f0055"><b>new </b></font><font color="#000000">IndexWriter</font><font color="#000000">(</font><font color="#000000">directory, analyzer, </font><font color="#7f0055"><b>true</b></font><font color="#000000">)</font><font color="#000000">;</font><br/>
+<font color="#ffffff"> </font><font color="#000000">iwriter.setMaxFieldLength</font><font color="#000000">(</font><font color="#990000">25000</font><font color="#000000">)</font><font color="#000000">;</font><br/>
<font color="#ffffff"> </font><font color="#000000">Document doc = </font><font color="#7f0055"><b>new </b></font><font color="#000000">Document</font><font color="#000000">()</font><font color="#000000">;</font><br/>
<font color="#ffffff"> </font><font color="#000000">String text = </font><font color="#2a00ff">"This is the text to be indexed."</font><font color="#000000">;</font><br/>
<font color="#ffffff"> </font><font color="#000000">doc.add</font><font color="#000000">(</font><font color="#7f0055"><b>new </b></font><font color="#000000">Field</font><font color="#000000">(</font><font color="#2a00ff">"fieldname"</font><font color="#000000">, text, Field.Store.YES,</font><br/>
Modified: lucene/java/trunk/src/test/org/apache/lucene/TestDemo.java
URL: http://svn.apache.org/viewcvs/lucene/java/trunk/src/test/org/apache/lucene/TestDemo.java?rev=178245&r1=178244&r2=178245&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/TestDemo.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/TestDemo.java Tue May 24 11:53:21 2005
@@ -51,6 +51,7 @@
// if one exists):
//Directory directory = FSDirectory.getDirectory("/tmp/testindex", true);
IndexWriter iwriter = new IndexWriter(directory, analyzer, true);
+ iwriter.setMaxFieldLength(25000);
Document doc = new Document();
String text = "This is the text to be indexed.";
doc.add(new Field("fieldname", text, Field.Store.YES,