lucene-java-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From whosc...@apache.org
Subject svn commit: r478045 - /lucene/java/trunk/contrib/memory/src/java/org/apache/lucene/index/memory/MemoryIndex.java
Date Wed, 22 Nov 2006 05:56:09 GMT
Author: whoschek
Date: Tue Nov 21 21:56:08 2006
New Revision: 478045

URL: http://svn.apache.org/viewvc?view=rev&rev=478045
Log:
example shouldn't use deprecated method

Modified:
    lucene/java/trunk/contrib/memory/src/java/org/apache/lucene/index/memory/MemoryIndex.java

Modified: lucene/java/trunk/contrib/memory/src/java/org/apache/lucene/index/memory/MemoryIndex.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/contrib/memory/src/java/org/apache/lucene/index/memory/MemoryIndex.java?view=diff&rev=478045&r1=478044&r2=478045
==============================================================================
--- lucene/java/trunk/contrib/memory/src/java/org/apache/lucene/index/memory/MemoryIndex.java
(original)
+++ lucene/java/trunk/contrib/memory/src/java/org/apache/lucene/index/memory/MemoryIndex.java
Tue Nov 21 21:56:08 2006
@@ -100,7 +100,8 @@
  * MemoryIndex index = new MemoryIndex();
  * index.addField("content", "Readings about Salmons and other select Alaska fishing Manuals",
analyzer);
  * index.addField("author", "Tales of James", analyzer);
- * float score = index.search(QueryParser.parse("+author:james +salmon~ +fish* manual~",
"content", analyzer));
+ * QueryParser parser = new QueryParser("content", analyzer);
+ * float score = index.search(parser.parse("+author:james +salmon~ +fish* manual~"));
  * if (score > 0.0f) {
  *     System.out.println("it's a match");
  * } else {



Mime
View raw message