Package org.xtreemfs.babudb.api.database

Examples of org.xtreemfs.babudb.api.database.Database.rangeLookup()


            ir.addInsert(1, (i + "").getBytes(), (i + "").getBytes());
            ir.addInsert(2, (i + "").getBytes(), (i + "").getBytes());
            db.insert(ir, null);
        }
       
        Iterator<Entry<byte[], byte[]>> it = db.rangeLookup(0, new byte[0], new byte[0], null).get();
        for (int i = 1000; i < 2000; i++)
            assertEquals(i + "", new String(it.next().getValue()));
        assertFalse(it.hasNext());
       
        it = db.rangeLookup(0, "1500".getBytes(), "1600".getBytes(), null).get();
View Full Code Here


        Iterator<Entry<byte[], byte[]>> it = db.rangeLookup(0, new byte[0], new byte[0], null).get();
        for (int i = 1000; i < 2000; i++)
            assertEquals(i + "", new String(it.next().getValue()));
        assertFalse(it.hasNext());
       
        it = db.rangeLookup(0, "1500".getBytes(), "1600".getBytes(), null).get();
        for (int i = 1500; i < 1600; i++)
            assertEquals(i + "", new String(it.next().getValue()));
        assertFalse(it.hasNext());
       
        database.getCheckpointer().checkpoint();
View Full Code Here

            assertEquals(i + "", new String(it.next().getValue()));
        assertFalse(it.hasNext());
       
        database.getCheckpointer().checkpoint();
       
        it = db.rangeLookup(0, "1500".getBytes(), "1600".getBytes(), null).get();
        for (int i = 1500; i < 1600; i++)
            assertEquals(i + "", new String(it.next().getValue()));
        assertFalse(it.hasNext());
       
        database.shutdown();
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.