// BTreeLeaf.h wdg 2009 #include "BTreeNode.h" BTreeLeaf::BTreeLeaf() : elements(0) {} BTreeLeaf * BTreeLeaf::insert(int item, int& newKey) { int pos=elements-1; while(pos>=0 && itemvalue[i] = value[i + (MAX+2)/2]; sibling->elements = (MAX+1)/2; elements -= (MAX+1)/2; newKey = sibling->value[0]; return sibling; } } void BTreeLeaf::dump(int depth) { indent(depth); if( elements> 0 ) { for(int i=0; i