Revision: 14790
          http://gate.svn.sourceforge.net/gate/?rev=14790&view=rev
Author:   ian_roberts
Date:     2011-12-16 12:43:24 +0000 (Fri, 16 Dec 2011)
Log Message:
-----------
Comment and whitespace fixes, no functional changes.

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

Modified: mimir/trunk/mimir-core/src/gate/mimir/search/FederatedQueryRunner.java
===================================================================
--- mimir/trunk/mimir-core/src/gate/mimir/search/FederatedQueryRunner.java      
2011-12-16 12:11:27 UTC (rev 14789)
+++ mimir/trunk/mimir-core/src/gate/mimir/search/FederatedQueryRunner.java      
2011-12-16 12:43:24 UTC (rev 14790)
@@ -3,7 +3,7 @@
  *
  *  Copyright (c) 2007-2011, The University of Sheffield.
  *
- *  This file is part of GATE Mímir (see http://gate.ac.uk/family/mimir.html), 
+ *  This file is part of GATE Mímir (see http://gate.ac.uk/family/mimir.html),
  *  and is free software, licenced under the GNU Lesser General Public License,
  *  Version 3, June 2007 (also included with this distribution as file
  *  LICENCE-LGPL3.html).
@@ -27,7 +27,7 @@
 import java.util.Set;
 
 /**
- * A {@link QueryRunner} that presents a set of sub-indexes (represented by 
+ * A {@link QueryRunner} that presents a set of sub-indexes (represented by
  * their own QueryRunners) as a single index.
  */
 public class FederatedQueryRunner implements QueryRunner {
@@ -48,22 +48,22 @@
   protected int[] nextSubRunnerRank;
   
   /**
-   * For each result document rank, this list supplies the index for the 
-   * sub-runner that supplied the document.  
+   * For each result document rank, this list supplies the index for the
+   * sub-runner that supplied the document.
    */
   protected IntList rank2runnerIndex;
   
   /**
-   * Which of the sub-runners has provided the previous document. This is an 
-   * instance field so that we can rotate the sub-runners (when the scores are 
-   * equal)  
+   * Which of the sub-runners has provided the previous document. This is an
+   * instance field so that we can rotate the sub-runners (when the scores are
+   * equal)
    */
   private int bestSubRunnerIndex = -1;
   
   /**
    * For each result document rank, this list supplies the rank of the document
-   * in sub-runner that supplied it.  
-   */  
+   * in sub-runner that supplied it.
+   */
   protected IntList rank2subRank;
   
   public FederatedQueryRunner(QueryRunner[] subrunners) {
@@ -146,19 +146,19 @@
           allOut = false;
           if(subRunners[i].getDocumentScore(nextSubRunnerRank[i]) > maxScore) {
             bestSubRunnerIndex = i;
-            maxScore = subRunners[i].getDocumentScore(nextSubRunnerRank[i]);   
       
-          }          
+            maxScore = subRunners[i].getDocumentScore(nextSubRunnerRank[i]);
+          }
         }
       }
       if(allOut) {
         // we ran out of docs
-        throw new IndexOutOfBoundsException("Requested rank was " + rank + 
+        throw new IndexOutOfBoundsException("Requested rank was " + rank +
           " but ran out of documents at " + nextRank + "!");
       }
-      // consume the next doc from subRunnerWithMin
+      // consume the next doc from bestSubRunnerIndex
       rank2runnerIndex.add(bestSubRunnerIndex);
       rank2subRank.add(nextSubRunnerRank[bestSubRunnerIndex]);
-      if(nextSubRunnerRank[bestSubRunnerIndex] < 
+      if(nextSubRunnerRank[bestSubRunnerIndex] <
           subRunners[bestSubRunnerIndex].getDocumentsCount() -1) {
         nextSubRunnerRank[bestSubRunnerIndex]++;
       } else {

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


------------------------------------------------------------------------------
Learn Windows Azure Live!  Tuesday, Dec 13, 2011
Microsoft is holding a special Learn Windows Azure training event for 
developers. It will provide a great way to learn Windows Azure and what it 
provides. You can attend the event by watching it streamed LIVE online.  
Learn more at http://p.sf.net/sfu/ms-windowsazure
_______________________________________________
GATE-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gate-cvs

Reply via email to