Sayonara Player
|
#include <Tree.h>
Public Member Functions | |
Tree (const T &data) | |
Tree * | addChild (Tree *node) |
adds a child to the given node More... | |
Tree * | addChild (const T &data) |
Tree * | removeChild (Tree *deletedNode) |
remove a node from the current node More... | |
void | sort (bool recursive) |
sort children of all nodes in ascending way according to their data More... | |
Public Attributes | |
Tree * | parent = nullptr |
T | data |
QList< Tree * > | children |
The Tree class.
|
inline |
adds a child to the given node
node | the parent node |
|
inline |
remove a node from the current node
deletedNode | node to remove |
|
inline |
sort children of all nodes in ascending way according to their data
recursive | if set to true, do it for all subnodes, too |