Reworked btree to be generic, using pointers