indiantarget / quimeraengine

0 stars 0 forks source link

Add methods to obtain the parent and the children of a node in QBinarySearchTree #633

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
This feature only makes sense if the user wants to traverse the tree in a 
custom manner.

QConstBinarySearchTreeIterator GetParent(QConstBinarySearchTreeIterator) const;
QConstBinarySearchTreeIterator GetLeftChild(QConstBinarySearchTreeIterator) 
const;
QConstBinarySearchTreeIterator GetRightChild(QConstBinarySearchTreeIterator) 
const;

The returned iterator will point to the end position when there is nothing to 
retrieve.
The input iterator cannot point to the end position.

Original issue reported on code.google.com by Lince3D@gmail.com on 15 Nov 2014 at 9:35

GoogleCodeExporter commented 9 years ago

Original comment by Lince3D@gmail.com on 9 Feb 2015 at 6:30