lucene-java-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From uschind...@apache.org
Subject svn commit: r806381 - in /lucene/java/trunk/src: java/org/apache/lucene/analysis/TokenStream.java test/org/apache/lucene/search/CachingWrapperFilterHelper.java
Date Thu, 20 Aug 2009 22:24:22 GMT
Author: uschindler
Date: Thu Aug 20 22:24:21 2009
New Revision: 806381

URL: http://svn.apache.org/viewvc?rev=806381&view=rev
Log:
LUCENE-1831: TokenWrapperAttributeFactory, CachingWrapperFilterHelper implements equals and
so should also implement hashCode

Modified:
    lucene/java/trunk/src/java/org/apache/lucene/analysis/TokenStream.java
    lucene/java/trunk/src/test/org/apache/lucene/search/CachingWrapperFilterHelper.java

Modified: lucene/java/trunk/src/java/org/apache/lucene/analysis/TokenStream.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/analysis/TokenStream.java?rev=806381&r1=806380&r2=806381&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/analysis/TokenStream.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/analysis/TokenStream.java Thu Aug 20 22:24:21
2009
@@ -146,6 +146,10 @@
       }
       return false;
     }
+    
+    public int hashCode() {
+      return delegate.hashCode() ^ 0x0a45ff31;
+    }
   }
 
   /**

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/CachingWrapperFilterHelper.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/CachingWrapperFilterHelper.java?rev=806381&r1=806380&r2=806381&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/CachingWrapperFilterHelper.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/CachingWrapperFilterHelper.java Thu
Aug 20 22:24:21 2009
@@ -77,4 +77,8 @@
     if (!(o instanceof CachingWrapperFilterHelper)) return false;
     return this.filter.equals((CachingWrapperFilterHelper)o);
   }
+  
+  public int hashCode() {
+    return this.filter.hashCode() ^ 0x5525aacb;
+  }
 }



Mime
View raw message