Examples of reset()


Examples of org.apache.lucene.store.RAMOutputStream.reset()

        int docID;

        if (docFreq <= lowFreqCutoff) {

          ros.reset();

          // Pack postings for low-freq terms into a single int[]:
          while ((docID = docsEnum2.nextDoc()) != DocsEnum.NO_MORE_DOCS) {
            scratch.add(docID);
            if (hasFreq) {
View Full Code Here

Examples of org.apache.lucene.util.ByteBlockPool.reset()

            assertEquals(j, reader.readVInt());
          }
        }
      }

      pool.reset();
    }
  }
}
View Full Code Here

Examples of org.apache.lucene.util.IntBlockPool.reset()

      for (int i = 0; i < num; i++) {
        assertEquals(i, reader.readInt());
      }
      assertTrue(reader.endOfSlice());
      if (random().nextBoolean()) {
        pool.reset(true, false);
        assertEquals(0, bytesUsed.get());
      } else {
        pool.reset(true, true);
        assertEquals(IntBlockPool.INT_BLOCK_SIZE
            * RamUsageEstimator.NUM_BYTES_INT, bytesUsed.get());
View Full Code Here

Examples of org.apache.lucene.util.IntBlockPool.SliceReader.reset()

      for (int j=0; j < info.terms.size(); j++) {
        int ord = info.sortedTerms[j];
        info.terms.get(ord, spare);
        int freq = sliceArray.freq[ord];
        result.append("\t'" + spare + "':" + freq + ":");
        postingsReader.reset(sliceArray.start[ord], sliceArray.end[ord]);
        result.append(" [");
        final int iters = storeOffsets ? 3 : 1;
        while(!postingsReader.endOfSlice()) {
          result.append("(");
         
View Full Code Here

Examples of org.apache.lucene.util.UnsafeByteArrayInputStream.reset()

    }
    ubais.mark(markIndex);
    for (int i = markIndex; i < bytes.length; i++) {
      ubais.read();
    }
    ubais.reset();
    assertEquals(bytes.length - markIndex, ubais.available());
  }
 
}
View Full Code Here

Examples of org.apache.maven.archetype.ui.ArchetypeConfiguration.reset()

                    confirmed = true;
                }
                else
                {
                    getLogger().debug( "Reseting archetype's definition and configuration" );
                    archetypeConfiguration.reset();
                    archetypeDefinition.reset();
                }
            } // end while
        }
        else
View Full Code Here

Examples of org.apache.maven.archetype.ui.ArchetypeDefinition.reset()

                }
                else
                {
                    getLogger().debug( "Reseting archetype's definition and configuration" );
                    archetypeConfiguration.reset();
                    archetypeDefinition.reset();
                }
            } // end while
        }
        else
        {
View Full Code Here

Examples of org.apache.maven.doxia.sink.SinkEventTestingSink.reset()

        Iterator<SinkEventElement> it = sink.getEventList().iterator();
        assertEquals( it, "verbatim", "link", "text", "link_", "verbatim_" );
        assertFalse( it.hasNext() );

        text = "<source><![CDATA[<a href=\"what.html\">what</a>]]></source>";
        sink.reset();
        parser.parse( text, sink );

        it = sink.getEventList().iterator();
        assertEquals( it, "verbatim", "text", "verbatim_" );
        assertFalse( it.hasNext() );
View Full Code Here

Examples of org.apache.maven.surefire.common.junit4.JUnitTestFailureListener.reset()

        {
            for ( int i = 0; i < rerunFailingTestsCount && !testFailureListener.getAllFailures().isEmpty(); i++ )
            {
                Map<Class<?>, Set<String>> failingTests =
                    JUnit4ProviderUtil.generateFailingTests( testFailureListener.getAllFailures(), testsToRun );
                testFailureListener.reset();
                final FilterFactory filterFactory = new FilterFactory( testClassLoader );
                Filter failingMethodsFilter = filterFactory.createFailingMethodFilter( failingTests );
                JUnitCoreWrapper.execute( testsToRun, jUnitCoreParameters, customRunListeners,
                                          filterFactory.and( filter, failingMethodsFilter ) );
            }
View Full Code Here

Examples of org.apache.maven.surefire.its.fixture.SurefireLauncher.reset()

    public void testOneExecutionRunInTwoBuilds()
    {
        SurefireLauncher launcher = unpack( "/surefire-803-multiFailsafeExec-rebuildOverwrites" );
        launcher.addD( "success", "false" ).executeVerifyWithFailure().assertIntegrationTestSuiteResults( 1, 0, 1, 0 );
        launcher.reset();
        launcher.addD( "success", "true" ).executeVerify().assertIntegrationTestSuiteResults( 1, 0, 0, 0 );
    }

}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.