コード例 #1
0
 @Override
 public void read() throws Exception {
   super.read();
   for (int q = 0; q < numQueries + 1; q++) {
     queryBoundaries[q] = readInt();
   }
   maxDocsPerQuery = 0;
   for (int q = 0; q < numQueries; q++) {
     int queryDocs = queryBoundaries[q + 1] - queryBoundaries[q];
     if (queryDocs > maxDocsPerQuery) {
       maxDocsPerQuery = queryDocs;
     }
   }
 }
コード例 #2
0
 @Override
 protected void readHeader() throws Exception {
   super.readHeader();
   numQueries = readInt();
   queryBoundaries = new int[numQueries + 1];
 }