Package krati.core.array.entry

Examples of krati.core.array.entry.EntryValueIntFactory


    public void testWriteReadEntry() throws Exception {
        cleanTestOutput();
       
        for(int run = 1; run <= 10; run++) {
            File file = new File(TEST_OUTPUT_DIR, "entry_test" + run + ".dat");
            Entry<EntryValueInt> entry = new SimpleEntry<EntryValueInt>(new EntryValueIntFactory(), 1000);
           
            for(int i = 0; i < 1000; i++) {
                entry.add(new EntryValueInt(i, random.nextInt(50000), i));
            }
            entry.save(file);
           
            Entry<EntryValueInt> entryRead = new SimpleEntry<EntryValueInt>(new EntryValueIntFactory(), 1000);
            entryRead.load(file);
           
            assertTrue("Entry minSCNs don't match at run " + run,
                                 entry.getMinScn() == entryRead.getMinScn());
            assertTrue("Entry maxSCNs don't match at run " + run,
View Full Code Here


     * Test SortEntriesByPos by having it sort values then
     * iterate over them to insure they're sorted.
     */
    public void testSortedEntryValues() {
        int c;
        EntryValueIntFactory valFactory = new EntryValueIntFactory();
       
        c = 0;
        Entry<EntryValueInt> e1 = new SimpleEntry<EntryValueInt>(valFactory, 10);
        for (int i = 9; i >= 0; i--) {
            e1.add(new EntryValueInt(i, c, c++));
View Full Code Here

TOP

Related Classes of krati.core.array.entry.EntryValueIntFactory

Copyright © 2018 www.massapicom. 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.