directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1566659 [1/6] - in /directory/mavibot/branches/with-txns/mavibot: img/ src/main/java/org/apache/directory/mavibot/btree/ src/main/java/org/apache/directory/mavibot/btree/comparator/ src/main/java/org/apache/directory/mavibot/btree/exceptio...
Date Mon, 10 Feb 2014 15:35:20 GMT
Author: elecharny
Date: Mon Feb 10 15:35:18 2014
New Revision: 1566659

URL: http://svn.apache.org/r1566659
Log:
Checked in the code I'm working on in a branch

Added:
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/InMemoryTransactionManager.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/TransactionManager.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/exception/FileException.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/exception/InvalidOffsetException.java
Modified:
    directory/mavibot/branches/with-txns/mavibot/img/btreeHeader.graphml
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractBTree.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractPage.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTree.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTreeFactory.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTreeHeader.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTreeTypeEnum.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/InMemoryBTree.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/InMemoryLeaf.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/InMemoryNode.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/NameRevisionComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/NameRevisionSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/Page.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/PageIO.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/PersistedBTree.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/PersistedBTreeBuilder.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/PersistedBTreeConfiguration.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/PersistedLeaf.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/PersistedNode.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/PersistedValueHolder.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/ReadTransaction.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/RecordManager.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/RevisionNameComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/RevisionNameSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/WriteTransaction.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/BooleanArrayComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/BooleanComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/ByteArrayComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/ByteComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/CharArrayComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/CharComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/IntArrayComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/IntComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/LongArrayComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/LongComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/ShortArrayComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/ShortComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/comparator/StringComparator.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/AbstractElementSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/BooleanSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/ByteArraySerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/ByteSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/CharArraySerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/CharSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/IntSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/LongArraySerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/LongSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/ShortSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/serializer/StringSerializer.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/InMemoryBTreeBuilderTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/InMemoryBTreeConfigurationTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/InMemoryBTreeDuplicateKeyTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/InMemoryBTreeFlushTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/InMemoryBTreeTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/InMemoryBTreeTestOps.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/InMemoryLeafTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/MultiThreadedInMemoryBtreeTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/PersistedBTreeBrowseTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/PersistedBTreeBuilderTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/PersistedBTreeDuplicateKeyTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/PersistedBTreeTransactionTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/PersistedStoreTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/RecordManagerFreePageTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/RecordManagerPrivateMethodTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/RecordManagerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/RecordManagerWithDuplicatesTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/RevisionNameComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/RevisionNameSerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/BooleanArrayComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/BooleanComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/ByteArrayComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/ByteComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/CharArrayComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/CharComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/IntArrayComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/IntComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/LongArrayComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/LongComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/ShortArrayComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/ShortComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/comparator/StringComparatorTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/BooleanSerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/ByteArraySerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/ByteSerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/CharSerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/IntSerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/LongSerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/ShortSerializerTest.java
    directory/mavibot/branches/with-txns/mavibot/src/test/java/org/apache/directory/mavibot/btree/serializer/StringSerializerTest.java

Modified: directory/mavibot/branches/with-txns/mavibot/img/btreeHeader.graphml
URL: http://svn.apache.org/viewvc/directory/mavibot/branches/with-txns/mavibot/img/btreeHeader.graphml?rev=1566659&r1=1566658&r2=1566659&view=diff
==============================================================================
--- directory/mavibot/branches/with-txns/mavibot/img/btreeHeader.graphml (original)
+++ directory/mavibot/branches/with-txns/mavibot/img/btreeHeader.graphml Mon Feb 10 15:35:18 2014
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <graphml xmlns="http://graphml.graphdrawing.org/xmlns" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:y="http://www.yworks.com/xml/graphml" xmlns:yed="http://www.yworks.com/xml/yed/3" xsi:schemaLocation="http://graphml.graphdrawing.org/xmlns http://www.yworks.com/xml/schema/graphml/1.1/ygraphml.xsd">
-  <!--Created by yFiles for Java 2.10-->
+  <!--Created by yFiles for Java 2.11-->
   <key for="graphml" id="d0" yfiles.type="resources"/>
   <key for="port" id="d1" yfiles.type="portgraphics"/>
   <key for="port" id="d2" yfiles.type="portgeometry"/>
@@ -17,10 +17,10 @@
     <node id="n0">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="346.0256" width="229.0" x="93.0" y="24.0"/>
+          <y:Geometry height="310.0256" width="229.0" x="93.0" y="24.0"/>
           <y:Fill color="#FFCC99" transparent="false"/>
           <y:BorderStyle hasColor="false" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="free" modelPosition="anywhere" textColor="#000000" visible="true" width="81.84765625" x="-85.84765625" y="4.0">BTree Header</y:NodeLabel>
+          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="free" modelPosition="anywhere" textColor="#000000" visible="true" width="81.84765625" x="73.576171875" y="-22.1328125">BTree Header</y:NodeLabel>
         </y:GenericNode>
       </data>
     </node>
@@ -444,7 +444,7 @@
     <node id="n28">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="99.0" y="181.0"/>
+          <y:Geometry height="30.0" width="27.0" x="99.0" y="144.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="internal" modelPosition="c" textColor="#000000" visible="true" width="4.0" x="11.5" y="13.0"/>
@@ -454,7 +454,7 @@
     <node id="n29">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="126.0" y="181.0"/>
+          <y:Geometry height="30.0" width="27.0" x="126.0" y="144.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -471,7 +471,7 @@
     <node id="n30">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="153.0" y="181.0"/>
+          <y:Geometry height="30.0" width="27.0" x="153.0" y="144.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -488,7 +488,7 @@
     <node id="n31">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="180.0" y="181.0"/>
+          <y:Geometry height="30.0" width="27.0" x="180.0" y="144.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="free" modelPosition="anywhere" textColor="#000000" visible="true" width="4.0" x="-78.4619140625" y="5.93359375"/>
@@ -498,7 +498,7 @@
     <node id="n32">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="108.0" x="99.0" y="181.0"/>
+          <y:Geometry height="30.0" width="108.0" x="99.0" y="144.0128"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="internal" modelPosition="l" textColor="#000000" visible="true" width="87.6953125" x="4.0" y="5.93359375">BTreePageSize</y:NodeLabel>
@@ -508,7 +508,7 @@
     <node id="n33">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="99.0" y="219.0"/>
+          <y:Geometry height="30.0" width="27.0" x="99.0" y="182.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="internal" modelPosition="c" textColor="#000000" visible="true" width="4.0" x="11.5" y="13.0"/>
@@ -518,7 +518,7 @@
     <node id="n34">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="126.0" y="219.0"/>
+          <y:Geometry height="30.0" width="27.0" x="126.0" y="182.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -535,7 +535,7 @@
     <node id="n35">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="153.0" y="219.0"/>
+          <y:Geometry height="30.0" width="27.0" x="153.0" y="182.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -552,7 +552,7 @@
     <node id="n36">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="180.0" y="219.0"/>
+          <y:Geometry height="30.0" width="27.0" x="180.0" y="182.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="free" modelPosition="anywhere" textColor="#000000" visible="true" width="4.0" x="-78.4619140625" y="5.93359375"/>
@@ -562,7 +562,7 @@
     <node id="n37">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="108.0" x="99.0" y="219.0"/>
+          <y:Geometry height="30.0" width="108.0" x="99.0" y="182.0128"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="internal" modelPosition="l" textColor="#000000" visible="true" width="72.53125" x="4.0" y="5.93359375">BTree name</y:NodeLabel>
@@ -572,7 +572,7 @@
     <node id="n38">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="70.0" x="210.0" y="219.0"/>
+          <y:Geometry height="30.0" width="70.0" x="210.0" y="182.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="31.1015625" y="5.93359375">
@@ -589,7 +589,7 @@
     <node id="n39">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="70.0" x="210.0" y="219.0"/>
+          <y:Geometry height="30.0" width="70.0" x="210.0" y="182.0128"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="35.8984375" x="17.05078125" y="5.93359375">xyz...<y:LabelModel>
@@ -605,7 +605,7 @@
     <node id="n40">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="99.0" y="257.0"/>
+          <y:Geometry height="30.0" width="27.0" x="99.0" y="220.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="internal" modelPosition="c" textColor="#000000" visible="true" width="4.0" x="11.5" y="13.0"/>
@@ -615,7 +615,7 @@
     <node id="n41">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="126.0" y="257.0"/>
+          <y:Geometry height="30.0" width="27.0" x="126.0" y="220.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -632,7 +632,7 @@
     <node id="n42">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="153.0" y="257.0"/>
+          <y:Geometry height="30.0" width="27.0" x="153.0" y="220.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -649,7 +649,7 @@
     <node id="n43">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="180.0" y="257.0"/>
+          <y:Geometry height="30.0" width="27.0" x="180.0" y="220.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="free" modelPosition="anywhere" textColor="#000000" visible="true" width="4.0" x="-78.4619140625" y="5.93359375"/>
@@ -659,7 +659,7 @@
     <node id="n44">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="108.0" x="99.0" y="257.0"/>
+          <y:Geometry height="30.0" width="108.0" x="99.0" y="220.0128"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="internal" modelPosition="l" textColor="#000000" visible="true" width="78.35546875" x="4.0" y="5.93359375">KeySerializer</y:NodeLabel>
@@ -669,7 +669,7 @@
     <node id="n45">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="70.0" x="210.0" y="257.0"/>
+          <y:Geometry height="30.0" width="70.0" x="210.0" y="220.0128"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="31.1015625" y="5.93359375">
@@ -686,7 +686,7 @@
     <node id="n46">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="70.0" x="210.0" y="257.0"/>
+          <y:Geometry height="30.0" width="70.0" x="210.0" y="220.0128"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="35.8984375" x="17.05078125" y="5.93359375">xyz...<y:LabelModel>
@@ -702,7 +702,7 @@
     <node id="n47">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="99.0" y="295.0"/>
+          <y:Geometry height="30.0" width="27.0" x="99.0" y="258.01279999999997"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="internal" modelPosition="c" textColor="#000000" visible="true" width="4.0" x="11.5" y="13.0"/>
@@ -712,7 +712,7 @@
     <node id="n48">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="126.0" y="295.0"/>
+          <y:Geometry height="30.0" width="27.0" x="126.0" y="258.01279999999997"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -729,7 +729,7 @@
     <node id="n49">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="153.0" y="295.0"/>
+          <y:Geometry height="30.0" width="27.0" x="153.0" y="258.01279999999997"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
@@ -746,7 +746,7 @@
     <node id="n50">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="180.0" y="295.0"/>
+          <y:Geometry height="30.0" width="27.0" x="180.0" y="258.01279999999997"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="free" modelPosition="anywhere" textColor="#000000" visible="true" width="4.0" x="-78.4619140625" y="5.93359375"/>
@@ -756,7 +756,7 @@
     <node id="n51">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="108.0" x="99.0" y="295.0"/>
+          <y:Geometry height="30.0" width="108.0" x="99.0" y="258.01279999999997"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="internal" modelPosition="l" textColor="#000000" visible="true" width="89.640625" x="4.0" y="5.93359375">ValueSerializer</y:NodeLabel>
@@ -766,7 +766,7 @@
     <node id="n52">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="70.0" x="210.0" y="295.0"/>
+          <y:Geometry height="30.0" width="70.0" x="210.0" y="258.01279999999997"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="31.1015625" y="5.93359375">
@@ -783,7 +783,7 @@
     <node id="n53">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="70.0" x="210.0" y="295.0"/>
+          <y:Geometry height="30.0" width="70.0" x="210.0" y="258.01279999999997"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="35.8984375" x="17.05078125" y="5.93359375">xyz...<y:LabelModel>
@@ -799,156 +799,17 @@
     <node id="n54">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="99.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
-<y:LabelModel>
-              <y:SmartNodeLabelModel distance="4.0"/>
-            </y:LabelModel>
-            <y:ModelParameter>
-              <y:SmartNodeLabelModelParameter labelRatioX="0.0" labelRatioY="0.0" nodeRatioX="0.0" nodeRatioY="0.0" offsetX="0.0" offsetY="0.0" upX="0.0" upY="-1.0"/>
-            </y:ModelParameter>
-          </y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n55">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="126.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
-<y:LabelModel>
-              <y:SmartNodeLabelModel distance="4.0"/>
-            </y:LabelModel>
-            <y:ModelParameter>
-              <y:SmartNodeLabelModelParameter labelRatioX="0.0" labelRatioY="0.0" nodeRatioX="0.0" nodeRatioY="0.0" offsetX="0.0" offsetY="0.0" upX="0.0" upY="-1.0"/>
-            </y:ModelParameter>
-          </y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n56">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="153.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
-<y:LabelModel>
-              <y:SmartNodeLabelModel distance="4.0"/>
-            </y:LabelModel>
-            <y:ModelParameter>
-              <y:SmartNodeLabelModelParameter labelRatioX="0.0" labelRatioY="0.0" nodeRatioX="0.0" nodeRatioY="0.0" offsetX="0.0" offsetY="0.0" upX="0.0" upY="-1.0"/>
-            </y:ModelParameter>
-          </y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n57">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="180.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
-<y:LabelModel>
-              <y:SmartNodeLabelModel distance="4.0"/>
-            </y:LabelModel>
-            <y:ModelParameter>
-              <y:SmartNodeLabelModelParameter labelRatioX="0.0" labelRatioY="0.0" nodeRatioX="0.0" nodeRatioY="0.0" offsetX="0.0" offsetY="0.0" upX="0.0" upY="-1.0"/>
-            </y:ModelParameter>
-          </y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n58">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="207.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
-<y:LabelModel>
-              <y:SmartNodeLabelModel distance="4.0"/>
-            </y:LabelModel>
-            <y:ModelParameter>
-              <y:SmartNodeLabelModelParameter labelRatioX="0.0" labelRatioY="0.0" nodeRatioX="0.0" nodeRatioY="0.0" offsetX="0.0" offsetY="0.0" upX="0.0" upY="-1.0"/>
-            </y:ModelParameter>
-          </y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n59">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="234.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
-<y:LabelModel>
-              <y:SmartNodeLabelModel distance="4.0"/>
-            </y:LabelModel>
-            <y:ModelParameter>
-              <y:SmartNodeLabelModelParameter labelRatioX="0.0" labelRatioY="0.0" nodeRatioX="0.0" nodeRatioY="0.0" offsetX="0.0" offsetY="0.0" upX="0.0" upY="-1.0"/>
-            </y:ModelParameter>
-          </y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n60">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="261.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="custom" textColor="#000000" visible="true" width="7.796875" x="9.6015625" y="5.93359375">
-<y:LabelModel>
-              <y:SmartNodeLabelModel distance="4.0"/>
-            </y:LabelModel>
-            <y:ModelParameter>
-              <y:SmartNodeLabelModelParameter labelRatioX="0.0" labelRatioY="0.0" nodeRatioX="0.0" nodeRatioY="0.0" offsetX="0.0" offsetY="0.0" upX="0.0" upY="-1.0"/>
-            </y:ModelParameter>
-          </y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n61">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="288.0" y="143.0"/>
-          <y:Fill color="#FFFF99" transparent="false"/>
-          <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="free" modelPosition="anywhere" textColor="#000000" visible="true" width="4.0" x="-184.7802734375" y="5.93359375"/>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n62">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="216.0" x="99.0" y="143.0"/>
-          <y:Fill hasColor="false" transparent="false"/>
-          <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
-          <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="internal" modelPosition="l" textColor="#000000" visible="true" width="102.349609375" x="4.0" y="5.93359375">NextBtreeHeader</y:NodeLabel>
-        </y:GenericNode>
-      </data>
-    </node>
-    <node id="n63">
-      <data key="d6">
-        <y:GenericNode configuration="ShinyPlateNodeWithShadow">
-          <y:Geometry height="30.0" width="27.0" x="99.0" y="333.0"/>
+          <y:Geometry height="30.0" width="27.0" x="99.0" y="296.01279999999997"/>
           <y:Fill color="#FFFF99" transparent="false"/>
           <y:BorderStyle color="#C0C0C0" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" hasText="false" height="4.0" modelName="internal" modelPosition="c" textColor="#000000" visible="true" width="4.0" x="11.5" y="13.0"/>
         </y:GenericNode>
       </data>
     </node>
-    <node id="n64">
+    <node id="n55">
       <data key="d6">
         <y:GenericNode configuration="ShinyPlateNode">
-          <y:Geometry height="30.0" width="27.0" x="99.0" y="333.0"/>
+          <y:Geometry height="30.0" width="27.0" x="99.0" y="296.01279999999997"/>
           <y:Fill hasColor="false" transparent="false"/>
           <y:BorderStyle color="#0000FF" type="line" width="1.0"/>
           <y:NodeLabel alignment="center" autoSizePolicy="content" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasBackgroundColor="false" hasLineColor="false" height="18.1328125" modelName="internal" modelPosition="l" textColor="#000000" visible="true" width="78.7421875" x="4.0" y="5.93359375">dupsAllowed</y:NodeLabel>

Modified: directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractBTree.java
URL: http://svn.apache.org/viewvc/directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractBTree.java?rev=1566659&r1=1566658&r2=1566659&view=diff
==============================================================================
--- directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractBTree.java (original)
+++ directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractBTree.java Mon Feb 10 15:35:18 2014
@@ -23,8 +23,10 @@ package org.apache.directory.mavibot.btr
 import java.io.IOException;
 import java.lang.reflect.Array;
 import java.util.Comparator;
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
 import java.util.concurrent.ConcurrentLinkedQueue;
-import java.util.concurrent.locks.ReentrantLock;
+import java.util.concurrent.atomic.AtomicLong;
 
 import org.apache.directory.mavibot.btree.exception.KeyNotFoundException;
 import org.apache.directory.mavibot.btree.serializer.ElementSerializer;
@@ -44,11 +46,8 @@ import org.apache.directory.mavibot.btre
     /** The read transaction timeout */
     protected long readTimeOut = DEFAULT_READ_TIMEOUT;
 
-    /** The Header for a managed BTree */
-    protected BTreeHeader btreeHeader;
-
-    /** The current rootPage */
-    protected volatile Page<K, V> rootPage;
+    /** The copied Header for a managed BTree */
+    //protected BTreeHeader<K, V> newBtreeHeader = new BTreeHeader<K, V>();
 
     /** The Key serializer used for this tree.*/
     protected ElementSerializer<K> keySerializer;
@@ -62,21 +61,35 @@ import org.apache.directory.mavibot.btre
     /** The size of the buffer used to write data in disk */
     protected int writeBufferSize;
 
-    /** A lock used to protect the write operation against concurrent access */
-    protected ReentrantLock writeLock;
-
     /** Flag to enable duplicate key support */
-    private boolean allowDuplicates;
+    protected boolean allowDuplicates;
+
+    /** The number of elements in a page for this B-tree */
+    protected int pageSize;
+
+    /** The BTree name */
+    protected String name;
+
+    /** The FQCN of the Key serializer */
+    protected String keySerializerFQCN;
+
+    /** The FQCN of the Value serializer */
+    protected String valueSerializerFQCN;
 
     /** The thread responsible for the cleanup of timed out reads */
     protected Thread readTransactionsThread;
 
     /** The BTree type : either in-memory, disk backed or persisted */
-    private BTreeTypeEnum type;
+    protected BTreeTypeEnum btreeType;
 
     /** The current transaction */
     protected WriteTransaction writeTransaction;
 
+    /** The map of all the used BtreeHeaders */
+    protected Map<Long, BTreeHeader<K, V>> btreeRevisions = new ConcurrentHashMap<Long, BTreeHeader<K, V>>();
+
+    /** The current revision */
+    protected AtomicLong currentRevision = new AtomicLong( 0L );
 
     /**
      * Starts a Read Only transaction. If the transaction is not closed, it will be
@@ -86,8 +99,25 @@ import org.apache.directory.mavibot.btre
      */
     protected ReadTransaction<K, V> beginReadTransaction()
     {
-        ReadTransaction<K, V> readTransaction = new ReadTransaction<K, V>( rootPage, btreeHeader.getRevision() - 1,
-            System.currentTimeMillis() );
+        BTreeHeader<K, V> btreeHeader = getBtreeHeader();
+
+        ReadTransaction<K, V> readTransaction = new ReadTransaction<K, V>( btreeHeader );
+
+        readTransactions.add( readTransaction );
+
+        return readTransaction;
+    }
+
+
+    /**
+     * Starts a Read Only transaction. If the transaction is not closed, it will be
+     * automatically closed after the timeout
+     *
+     * @return The created transaction
+     */
+    protected ReadTransaction<K, V> beginReadTransaction( long revision )
+    {
+        ReadTransaction<K, V> readTransaction = new ReadTransaction<K, V>( getBtreeHeader( revision ) );
 
         readTransactions.add( readTransaction );
 
@@ -102,10 +132,9 @@ import org.apache.directory.mavibot.btre
     {
         ReadTransaction<K, V> transaction = beginReadTransaction();
 
-        // Fetch the root page for this revision
         ParentPos<K, V>[] stack = (ParentPos<K, V>[]) Array.newInstance( ParentPos.class, 32 );
 
-        TupleCursor<K, V> cursor = rootPage.browse( transaction, stack, 0 );
+        TupleCursor<K, V> cursor = transaction.getRootPage().browse( transaction, stack, 0 );
 
         // Set the position before the first element
         cursor.beforeFirst();
@@ -119,15 +148,12 @@ import org.apache.directory.mavibot.btre
      */
     public TupleCursor<K, V> browse( long revision ) throws IOException, KeyNotFoundException
     {
-        ReadTransaction<K, V> transaction = beginReadTransaction();
-
-        // Fetch the root page for this revision
-        Page<K, V> revisionRootPage = getRootPage( revision );
+        ReadTransaction<K, V> transaction = beginReadTransaction( revision );
 
         ParentPos<K, V>[] stack = (ParentPos<K, V>[]) Array.newInstance( ParentPos.class, 32 );
 
         // And get the cursor
-        TupleCursor<K, V> cursor = revisionRootPage.browse( transaction, stack, 0 );
+        TupleCursor<K, V> cursor = transaction.getRootPage().browse( transaction, stack, 0 );
 
         return cursor;
     }
@@ -140,10 +166,9 @@ import org.apache.directory.mavibot.btre
     {
         ReadTransaction<K, V> transaction = beginReadTransaction();
 
-        // Fetch the root page for this revision
         ParentPos<K, V>[] stack = (ParentPos<K, V>[]) Array.newInstance( ParentPos.class, 32 );
 
-        TupleCursor<K, V> cursor = rootPage.browse( key, transaction, stack, 0 );
+        TupleCursor<K, V> cursor = transaction.getRootPage().browse( key, transaction, stack, 0 );
 
         return cursor;
     }
@@ -154,15 +179,12 @@ import org.apache.directory.mavibot.btre
      */
     public TupleCursor<K, V> browseFrom( long revision, K key ) throws IOException, KeyNotFoundException
     {
-        ReadTransaction<K, V> transaction = beginReadTransaction();
-
-        // Fetch the rootPage for this revision
-        Page<K, V> revisionRootPage = getRootPage( revision );
+        ReadTransaction<K, V> transaction = beginReadTransaction( revision );
 
         ParentPos<K, V>[] stack = (ParentPos<K, V>[]) Array.newInstance( ParentPos.class, 32 );
 
         // And get the cursor
-        TupleCursor<K, V> cursor = revisionRootPage.browse( key, transaction, stack, 0 );
+        TupleCursor<K, V> cursor = transaction.getRootPage().browse( key, transaction, stack, 0 );
 
         return cursor;
     }
@@ -173,7 +195,16 @@ import org.apache.directory.mavibot.btre
      */
     public boolean contains( K key, V value ) throws IOException
     {
-        return rootPage.contains( key, value );
+        ReadTransaction<K, V> transaction = beginReadTransaction();
+
+        try
+        {
+            return transaction.getRootPage().contains( key, value );
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -183,9 +214,16 @@ import org.apache.directory.mavibot.btre
     public boolean contains( long revision, K key, V value ) throws IOException, KeyNotFoundException
     {
         // Fetch the root page for this revision
-        Page<K, V> revisionRootPage = getRootPage( revision );
+        ReadTransaction<K, V> transaction = beginReadTransaction( revision );
 
-        return revisionRootPage.contains( key, value );
+        try
+        {
+            return transaction.getRootPage().contains( key, value );
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -199,9 +237,7 @@ import org.apache.directory.mavibot.btre
             throw new IllegalArgumentException( "Key must not be null" );
         }
 
-        long revision = generateRevision();
-
-        Tuple<K, V> deleted = delete( key, revision );
+        Tuple<K, V> deleted = delete( key, currentRevision.get() + 1 );
 
         return deleted;
     }
@@ -222,9 +258,7 @@ import org.apache.directory.mavibot.btre
             throw new IllegalArgumentException( "Value must not be null" );
         }
 
-        long revision = generateRevision();
-
-        Tuple<K, V> deleted = delete( key, value, revision );
+        Tuple<K, V> deleted = delete( key, value, currentRevision.get() + 1 );
 
         return deleted;
     }
@@ -251,31 +285,13 @@ import org.apache.directory.mavibot.btre
      */
     public V insert( K key, V value ) throws IOException
     {
-        long revision = generateRevision();
-
         V existingValue = null;
 
-        try
-        {
-            if ( writeTransaction == null )
-            {
-                writeLock.lock();
-            }
-
-            InsertResult<K, V> result = insert( key, value, revision );
+        InsertResult<K, V> result = insert( key, value, -1L );
 
-            if ( result instanceof ModifyResult )
-            {
-                existingValue = ( ( ModifyResult<K, V> ) result ).getModifiedValue();
-            }
-        }
-        finally
+        if ( result instanceof ModifyResult )
         {
-            // See above
-            if ( writeTransaction == null )
-            {
-                writeLock.unlock();
-            }
+            existingValue = ( ( ModifyResult<K, V> ) result ).getModifiedValue();
         }
 
         return existingValue;
@@ -302,7 +318,16 @@ import org.apache.directory.mavibot.btre
      */
     public V get( K key ) throws IOException, KeyNotFoundException
     {
-        return rootPage.get( key );
+        ReadTransaction<K, V> transaction = beginReadTransaction();
+
+        try
+        {
+            return transaction.getRootPage().get( key );
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -311,29 +336,29 @@ import org.apache.directory.mavibot.btre
      */
     public V get( long revision, K key ) throws IOException, KeyNotFoundException
     {
-        // Fetch the root page for this revision
-        Page<K, V> revisionRootPage = getRootPage( revision );
+        ReadTransaction<K, V> transaction = beginReadTransaction( revision );
 
-        return revisionRootPage.get( key );
+        try
+        {
+            return transaction.getRootPage().get( key );
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
     /**
      * {@inheritDoc}
      */
-    public Page<K, V> getRootPage()
-    {
-        return rootPage;
-    }
+    public abstract Page<K, V> getRootPage();
 
 
     /**
      * {@inheritDoc}
      */
-    /* no qualifier */void setRootPage( Page<K, V> root )
-    {
-        rootPage = root;
-    }
+    /* no qualifier */abstract void setRootPage( Page<K, V> root );
 
 
     /**
@@ -341,7 +366,16 @@ import org.apache.directory.mavibot.btre
      */
     public ValueCursor<V> getValues( K key ) throws IOException, KeyNotFoundException
     {
-        return rootPage.getValues( key );
+        ReadTransaction<K, V> transaction = beginReadTransaction();
+
+        try
+        {
+            return transaction.getRootPage().getValues( key );
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -355,7 +389,16 @@ import org.apache.directory.mavibot.btre
             return false;
         }
 
-        return rootPage.hasKey( key );
+        ReadTransaction<K, V> transaction = beginReadTransaction();
+
+        try
+        {
+            return transaction.getRootPage().hasKey( key );
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -369,10 +412,16 @@ import org.apache.directory.mavibot.btre
             return false;
         }
 
-        // Fetch the root page for this revision
-        Page<K, V> revisionRootPage = getRootPage( revision );
+        ReadTransaction<K, V> transaction = beginReadTransaction( revision );
 
-        return revisionRootPage.hasKey( key );
+        try
+        {
+            return transaction.getRootPage().hasKey( key );
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -391,7 +440,7 @@ import org.apache.directory.mavibot.btre
     public void setKeySerializer( ElementSerializer<K> keySerializer )
     {
         this.keySerializer = keySerializer;
-        btreeHeader.setKeySerializerFQCN( keySerializer.getClass().getName() );
+        keySerializerFQCN = keySerializer.getClass().getName();
     }
 
 
@@ -400,7 +449,7 @@ import org.apache.directory.mavibot.btre
      */
     public String getKeySerializerFQCN()
     {
-        return btreeHeader.getKeySerializerFQCN();
+        return keySerializerFQCN;
     }
 
 
@@ -419,7 +468,7 @@ import org.apache.directory.mavibot.btre
     public void setValueSerializer( ElementSerializer<V> valueSerializer )
     {
         this.valueSerializer = valueSerializer;
-        btreeHeader.setValueSerializerFQCN( valueSerializer.getClass().getName() );
+        valueSerializerFQCN = valueSerializer.getClass().getName();
     }
 
 
@@ -428,7 +477,7 @@ import org.apache.directory.mavibot.btre
      */
     public String getValueSerializerFQCN()
     {
-        return btreeHeader.getValueSerializerFQCN();
+        return valueSerializerFQCN;
     }
 
 
@@ -437,7 +486,16 @@ import org.apache.directory.mavibot.btre
      */
     public long getRevision()
     {
-        return btreeHeader.getRevision();
+        ReadTransaction<K, V> transaction = beginReadTransaction();
+
+        try
+        {
+            return transaction.getRevision();
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -446,18 +504,23 @@ import org.apache.directory.mavibot.btre
      */
     /* no qualifier */void setRevision( long revision )
     {
-        btreeHeader.setRevision( revision );
+        getBtreeHeader().setRevision( revision );
     }
 
 
     /**
-     * Generates a new revision number. It's only used by the Page instances.
-     *
-     * @return a new incremental revision number
+     * Store the new revision in the map of btrees, increment the current revision
      */
-    /* no qualifier */long generateRevision()
+    protected void storeRevision( BTreeHeader<K, V> btreeHeader )
     {
-        return btreeHeader.incrementRevision();
+        long revision = btreeHeader.getRevision();
+
+        synchronized ( btreeRevisions )
+        {
+            btreeRevisions.put( revision, btreeHeader );
+        }
+
+        currentRevision.set( revision );
     }
 
 
@@ -484,7 +547,16 @@ import org.apache.directory.mavibot.btre
      */
     public long getNbElems()
     {
-        return btreeHeader.getNbElems();
+        ReadTransaction<K, V> transaction = beginReadTransaction();
+
+        try
+        {
+            return transaction.getBtreeHeader().getNbElems();
+        }
+        finally
+        {
+            transaction.close();
+        }
     }
 
 
@@ -493,7 +565,7 @@ import org.apache.directory.mavibot.btre
      */
     /* no qualifier */void setNbElems( long nbElems )
     {
-        btreeHeader.setNbElems( nbElems );
+        getBtreeHeader().setNbElems( nbElems );
     }
 
 
@@ -502,7 +574,7 @@ import org.apache.directory.mavibot.btre
      */
     public int getPageSize()
     {
-        return btreeHeader.getPageSize();
+        return pageSize;
     }
 
 
@@ -513,11 +585,11 @@ import org.apache.directory.mavibot.btre
     {
         if ( pageSize <= 2 )
         {
-            btreeHeader.setPageSize( DEFAULT_PAGE_SIZE );
+            this.pageSize = DEFAULT_PAGE_SIZE;
         }
         else
         {
-            btreeHeader.setPageSize( getPowerOf2( pageSize ) );
+            this.pageSize = getPowerOf2( pageSize );
         }
     }
 
@@ -527,7 +599,7 @@ import org.apache.directory.mavibot.btre
      */
     public String getName()
     {
-        return btreeHeader.getName();
+        return name;
     }
 
 
@@ -536,7 +608,7 @@ import org.apache.directory.mavibot.btre
      */
     public void setName( String name )
     {
-        btreeHeader.setName( name );
+        this.name = name;
     }
 
 
@@ -572,7 +644,7 @@ import org.apache.directory.mavibot.btre
      */
     public boolean isAllowDuplicates()
     {
-        return btreeHeader.isAllowDuplicates();
+        return allowDuplicates;
     }
 
 
@@ -581,7 +653,7 @@ import org.apache.directory.mavibot.btre
      */
     public void setAllowDuplicates( boolean allowDuplicates )
     {
-        btreeHeader.setAllowDuplicates( allowDuplicates );
+        this.allowDuplicates = allowDuplicates;
     }
 
 
@@ -590,7 +662,7 @@ import org.apache.directory.mavibot.btre
      */
     public BTreeTypeEnum getType()
     {
-        return type;
+        return btreeType;
     }
 
 
@@ -599,7 +671,7 @@ import org.apache.directory.mavibot.btre
      */
     public void setType( BTreeTypeEnum type )
     {
-        this.type = type;
+        this.btreeType = type;
     }
 
 
@@ -621,6 +693,30 @@ import org.apache.directory.mavibot.btre
 
 
     /**
+     * @return The current BtreeHeader
+     */
+    protected BTreeHeader<K, V> getBtreeHeader()
+    {
+        synchronized ( btreeRevisions )
+        {
+            long revision = currentRevision.get();
+            BTreeHeader<K, V> btreeHeader = btreeRevisions.get( revision );
+
+            return btreeHeader;
+        }
+    }
+
+
+    /**
+     * @return The current BtreeHeader
+     */
+    protected BTreeHeader<K, V> getBtreeHeader( long revision )
+    {
+        return btreeRevisions.get( revision );
+    }
+
+
+    /**
      * Create a thread that is responsible of cleaning the transactions when
      * they hit the timeout
      */
@@ -657,6 +753,12 @@ import org.apache.directory.mavibot.btre
                             {
                                 transaction.close();
                                 readTransactions.poll();
+
+                                synchronized ( btreeRevisions )
+                                {
+                                    btreeRevisions.remove( transaction.getRevision() );
+                                }
+
                                 continue;
                             }
 

Modified: directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractPage.java
URL: http://svn.apache.org/viewvc/directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractPage.java?rev=1566659&r1=1566658&r2=1566659&view=diff
==============================================================================
--- directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractPage.java (original)
+++ directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/AbstractPage.java Mon Feb 10 15:35:18 2014
@@ -23,8 +23,6 @@ package org.apache.directory.mavibot.btr
 import java.io.IOException;
 import java.lang.reflect.Array;
 
-import org.apache.directory.mavibot.btree.KeyHolder;
-import org.apache.directory.mavibot.btree.Page;
 import org.apache.directory.mavibot.btree.exception.EndOfFileExceededException;
 import org.apache.directory.mavibot.btree.exception.KeyNotFoundException;
 
@@ -32,7 +30,7 @@ import org.apache.directory.mavibot.btre
 /**
  * A MVCC abstract Page. It stores the field and the methods shared by the Node and Leaf
  * classes.
- * 
+ *
  * @param <K> The type for the Key
  * @param <V> The type for the stored value
  *
@@ -68,7 +66,7 @@ import org.apache.directory.mavibot.btre
 
     /**
      * Creates a default empty AbstractPage
-     * 
+     *
      * @param btree The associated BTree
      */
     protected AbstractPage( BTree<K, V> btree )
@@ -216,6 +214,31 @@ import org.apache.directory.mavibot.btre
     /**
      * {@inheritDoc}
      */
+    @SuppressWarnings("unchecked")
+    public DeleteResult<K, V> delete( K key, V value, long revision ) throws IOException
+    {
+        return delete( key, value, revision, null, -1 );
+    }
+
+
+    /**
+     * The real delete implementation. It can be used for internal deletion in the B-tree.
+     *
+     * @param key The key to delete
+     * @param value The value to delete
+     * @param revision The revision for which we want to delete a tuple
+     * @param parent The parent page
+     * @param parentPos The position of this page in the parent page
+     * @return The result
+     * @throws IOException If we had an issue while processing the deletion
+     */
+    /* no qualifier */abstract DeleteResult<K, V> delete( K key, V value, long revision, Page<K, V> parent, int parentPos )
+        throws IOException;
+
+
+    /**
+     * {@inheritDoc}
+     */
     public V get( K key ) throws IOException, KeyNotFoundException
     {
         int pos = findPos( key );
@@ -299,7 +322,7 @@ import org.apache.directory.mavibot.btre
     /**
      * Selects the sibling (the previous or next page with the same parent) which has
      * the more element assuming it's above N/2
-     * 
+     *
      * @param parent The parent of the current page
      * @param The position of the current page reference in its parent
      * @return The position of the sibling, or -1 if we have'nt found any sibling
@@ -403,7 +426,7 @@ import org.apache.directory.mavibot.btre
 
     /**
      * Sets the key at a give position
-     * 
+     *
      * @param pos The position in the keys array
      * @param key the key to inject
      */
@@ -452,7 +475,7 @@ import org.apache.directory.mavibot.btre
 
     /**
      * Compares two keys
-     * 
+     *
      * @param key1 The first key
      * @param key2 The second key
      * @return -1 if the first key is above the second one, 1 if it's below, and 0
@@ -510,8 +533,8 @@ import org.apache.directory.mavibot.btre
      * <li>'h' will return -4</li>
      * <li>'i' will return 4</li>
      * </ul>
-     * 
-     * 
+     *
+     *
      * @param key The key to find
      * @return The position in the page.
      */

Modified: directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTree.java
URL: http://svn.apache.org/viewvc/directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTree.java?rev=1566659&r1=1566658&r2=1566659&view=diff
==============================================================================
--- directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTree.java (original)
+++ directory/mavibot/branches/with-txns/mavibot/src/main/java/org/apache/directory/mavibot/btree/BTree.java Mon Feb 10 15:35:18 2014
@@ -28,7 +28,7 @@ import org.apache.directory.mavibot.btre
 
 
 /**
- * A BTree interface, to be implemented by the PersistedBTree or the InMemoryBTree
+ * A B-tree interface, to be implemented by the PersistedBTree or the InMemoryBTree
  *
  * @param <K> The Key type
  * @param <V> The Value type
@@ -46,23 +46,15 @@ public interface BTree<K, V>
     /** Define a default delay for a read transaction. This is 10 seconds */
     static final long DEFAULT_READ_TIMEOUT = 10 * 1000L;
 
-    /** The BTree allows duplicate values */
+    /** The B-tree allows duplicate values */
     static final boolean ALLOW_DUPLICATES = true;
 
-    /** The BTree forbids duplicate values */
+    /** The B-tree forbids duplicate values */
     static final boolean FORBID_DUPLICATES = false;
 
 
     /**
-     * Initialize the BTree.
-     *
-     * @throws IOException If we get some exception while initializing the BTree
-     */
-    void init() throws IOException;
-
-
-    /**
-     * Close the BTree, cleaning up all the data structure
+     * Close the B-tree, cleaning up all the data structure
      */
     void close() throws IOException;
 
@@ -87,10 +79,10 @@ public interface BTree<K, V>
 
 
     /**
-     * Insert an entry in the BTree.
+     * Insert an entry in the B-tree.
      * <p>
      * We will replace the value if the provided key already exists in the
-     * btree.
+     * B-tree.
      *
      * @param key Inserted key
      * @param value Inserted value
@@ -130,7 +122,7 @@ public interface BTree<K, V>
      *
      * @param key The key we are looking at
      * @return The found value, or null if the key is not present in the tree
-     * @throws KeyNotFoundException If the key is not found in the BTree
+     * @throws KeyNotFoundException If the key is not found in the B-tree
      * @throws IOException TODO
      */
     V get( K key ) throws IOException, KeyNotFoundException;
@@ -142,7 +134,7 @@ public interface BTree<K, V>
      * @param revision The revision we are looking for
      * @return The rootPage associated to this revision
      * @throws IOException If we had an issue while accessing the underlying file
-     * @throws KeyNotFoundException If the revision does not exist for this Btree
+     * @throws KeyNotFoundException If the revision does not exist for this B-tree
      */
     Page<K, V> getRootPage( long revision ) throws IOException, KeyNotFoundException;
 
@@ -169,7 +161,7 @@ public interface BTree<K, V>
      * @param revision The revision for which we want to find a key
      * @param key The key we are looking at
      * @return The found value, or null if the key is not present in the tree
-     * @throws KeyNotFoundException If the key is not found in the BTree
+     * @throws KeyNotFoundException If the key is not found in the B-tree
      * @throws IOException If there was an issue while fetching data from the disk
      */
     V get( long revision, K key ) throws IOException, KeyNotFoundException;
@@ -192,13 +184,13 @@ public interface BTree<K, V>
      * @param key The key we are looking at
      * @return true if the key is present, false otherwise
      * @throws IOException If we have an error while trying to access the page
-     * @throws KeyNotFoundException If the key is not found in the BTree
+     * @throws KeyNotFoundException If the key is not found in the B-tree
      */
     boolean hasKey( long revision, K key ) throws IOException, KeyNotFoundException;
 
 
     /**
-     * Checks if the BTree contains the given key with the given value.
+     * Checks if the B-tree contains the given key with the given value.
      *
      * @param key The key we are looking for
      * @param value The value associated with the given key
@@ -208,13 +200,13 @@ public interface BTree<K, V>
 
 
     /**
-     * Checks if the BTree contains the given key with the given value for a given revision
+     * Checks if the B-tree contains the given key with the given value for a given revision
      *
      * @param revision The revision we would like to browse
      * @param key The key we are looking for
      * @param value The value associated with the given key
      * @return true if the key and value are associated with each other, false otherwise
-     * @throws KeyNotFoundException If the key is not found in the BTree
+     * @throws KeyNotFoundException If the key is not found in the B-tree
      */
     boolean contains( long revision, K key, V value ) throws IOException, KeyNotFoundException;
 
@@ -222,7 +214,7 @@ public interface BTree<K, V>
     /**
      * Creates a cursor starting at the beginning of the tree
      *
-     * @return A cursor on the btree
+     * @return A cursor on the B-tree
      * @throws IOException
      */
     TupleCursor<K, V> browse() throws IOException;
@@ -232,9 +224,9 @@ public interface BTree<K, V>
      * Creates a cursor starting at the beginning of the tree, for a given revision
      *
      * @param revision The revision we would like to browse
-     * @return A cursor on the btree
+     * @return A cursor on the B-tree
      * @throws IOException If we had an issue while fetching data from the disk
-     * @throws KeyNotFoundException If the key is not found in the BTree
+     * @throws KeyNotFoundException If the key is not found in the B-tree
      */
     TupleCursor<K, V> browse( long revision ) throws IOException, KeyNotFoundException;
 
@@ -244,7 +236,7 @@ public interface BTree<K, V>
      *
      * @param key The key which is the starting point. If the key is not found,
      * then the cursor will always return null.
-     * @return A cursor on the btree
+     * @return A cursor on the B-tree
      * @throws IOException
      */
     TupleCursor<K, V> browseFrom( K key ) throws IOException;
@@ -256,8 +248,8 @@ public interface BTree<K, V>
      * @param The revision we are looking for
      * @param key The key which is the starting point. If the key is not found,
      * then the cursor will always return null.
-     * @return A cursor on the btree
-     * @throws IOException If wxe had an issue reading the BTree from disk
+     * @return A cursor on the B-tree
+     * @throws IOException If wxe had an issue reading the B-tree from disk
      * @throws KeyNotFoundException  If we can't find a rootPage for this revision
      */
     TupleCursor<K, V> browseFrom( long revision, K key ) throws IOException, KeyNotFoundException;
@@ -349,25 +341,25 @@ public interface BTree<K, V>
 
 
     /**
-     * @return The current BTree revision
+     * @return The current B-tree revision
      */
     long getRevision();
 
 
     /**
-     * @return The current number of elements in the BTree
+     * @return The current number of elements in the B-tree
      */
     long getNbElems();
 
 
     /**
-     * @return true if this BTree allow duplicate values
+     * @return true if this B-tree allow duplicate values
      */
     boolean isAllowDuplicates();
 
 
     /**
-     * @param allowDuplicates True if the BTree will allow duplicate values
+     * @param allowDuplicates True if the B-tree will allow duplicate values
      */
     void setAllowDuplicates( boolean allowDuplicates );
 



Mime
View raw message