X-Git-Url: https://git.llucax.com/z.facultad/75.52/treemulator.git/blobdiff_plain/ecf0c05bcdc4ea9457feae6ef43378afc89a2fe1..bb83fdaa6e234bff23810b22fca3a098e2afb975:/src/btree_data.h diff --git a/src/btree_data.h b/src/btree_data.h index 7ea7d9c..db8ecc1 100644 --- a/src/btree_data.h +++ b/src/btree_data.h @@ -19,8 +19,11 @@ class BTreeData { virtual uchar *ToArray () const; Clave* getClave () { return clave; } + uint getChild () { return hijo; } + void setChild (uint c) { hijo = c; } bool operator < (const BTreeData &data) const; + bool operator == (const BTreeData &data) const; virtual operator std::string () const { std::string out = (*clave); std::stringstream ss; @@ -53,7 +56,7 @@ class BTreeLeafData:public BTreeData { class BTreeChildData:public BTreeData { public: - BTreeChildData (uint child):BTreeData () { hijo = child; } + BTreeChildData (uint child):BTreeData () { hijo = child; clave = NULL; } BTreeChildData (uchar *node); virtual ~BTreeChildData ();