Revision: 16783
          http://sourceforge.net/p/gate/code/16783
Author:   valyt
Date:     2013-08-14 15:30:34 +0000 (Wed, 14 Aug 2013)
Log Message:
-----------
Bugfix: mg4j 5 uses END_OF_LIST constant, not negative values.

Modified Paths:
--------------
    mimir/trunk/mimir-core/src/gate/mimir/search/terms/AnnotationTermsQuery.java

Modified: 
mimir/trunk/mimir-core/src/gate/mimir/search/terms/AnnotationTermsQuery.java
===================================================================
--- 
mimir/trunk/mimir-core/src/gate/mimir/search/terms/AnnotationTermsQuery.java    
    2013-08-14 08:40:44 UTC (rev 16782)
+++ 
mimir/trunk/mimir-core/src/gate/mimir/search/terms/AnnotationTermsQuery.java    
    2013-08-14 15:30:34 UTC (rev 16783)
@@ -21,6 +21,7 @@
 import gate.mimir.search.query.AnnotationQuery;
 
 import it.unimi.di.big.mg4j.index.IndexIterator;
+import it.unimi.di.big.mg4j.search.DocumentIterator;
 import it.unimi.di.big.mg4j.index.IndexReader;
 
 import java.io.IOException;
@@ -108,7 +109,7 @@
           if(countsEnabled) {
             counts[index] = 0;
             IndexIterator iIter = 
annotationIndexReader.documents(terms[index]);
-            while(iIter.nextDocument() >= 0) {
+            while(iIter.nextDocument() != DocumentIterator.END_OF_LIST) {
               counts[index] += iIter.count();
             }
           }

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead. 
Download for free and get started troubleshooting in minutes. 
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk
_______________________________________________
GATE-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gate-cvs

Reply via email to