public QualityStats[] execute(Judge judge,SubmissionReport submitRep,PrintWriter qualityLog) throws Exception {
  int nQueries=Math.min(maxQueries,qualityQueries.length);
  QualityStats stats[]=new QualityStats[nQueries];
  for (int i=0; i < nQueries; i++) {
    QualityQuery qq=qualityQueries[i];
    Query q=qqParser.parse(qq);
    long t1=System.currentTimeMillis();
    TopDocs td=searcher.search(q,maxResults);
    long searchTime=System.currentTimeMillis() - t1;
    if (judge != null) {
      stats[i]=analyzeQueryResults(qq,q,td,judge,qualityLog,searchTime);
    }
    if (submitRep != null) {
      submitRep.report(qq,td,docNameField,searcher);
    }
  }
  if (submitRep != null) {
    submitRep.flush();
  }
  return stats;
}

public QualityStats [ ] execute ( Judge judge , SubmissionReport submitRep , PrintWriter qualityLog ) throws Exception { int nQueries = Math . min ( maxQueries , qualityQueries . length ) ; QualityStats stats [ ] = new QualityStats [ nQueries ] ; for ( int i = 0 ; i < nQueries ; i ++ ) { QualityQuery qq = qualityQueries [ i ] ; Query q = qqParser . parse ( qq ) ; long t1 = System . currentTimeMillis ( ) ; TopDocs td = searcher . search ( q , maxResults ) ; long searchTime = System . currentTimeMillis ( ) - t1 ; if ( judge != null ) { stats [ i ] = analyzeQueryResults ( qq , q , td , judge , qualityLog , searchTime ) ; } if ( submitRep != null ) { submitRep . report ( qq , td , docNameField , searcher ) ; } } if ( submitRep != null ) { submitRep . flush ( ) ; } return stats ; }
run the quality benchmark .
