X-Git-Url: https://git.llucax.com/z.facultad/75.52/treemulator.git/blobdiff_plain/226df952388af8a4955b26b1ef0b5e1784103bf5..e642d903800bc569707379b4a7f48293077d3c99:/src/btree.cpp diff --git a/src/btree.cpp b/src/btree.cpp index dd0551d..ef48fef 100644 --- a/src/btree.cpp +++ b/src/btree.cpp @@ -152,3 +152,23 @@ void BTree::WriteKeys (uchar *node, BTreeNodeHeader &node_header, std::list node_keys = ReadKeys (node, node_header); + std::list::iterator it = node_keys.begin (); + + std::cout << "Nodo : " << num << std::endl; + std::cout << "Items : " << node_header.item_count << std::endl; + std::cout << "Free : " << node_header.free_space << " (" << (header.block_size - sizeof (BTreeNodeHeader)) << ")" << std::endl; + while (it != node_keys.end ()) { + std::string s = (*it); + std::cout << "(" << s << ") "; + } + std::cout << std::endl; +} +