21 #ifndef ELM_DATA_TREE_H
22 #define ELM_DATA_TREE_H
24 #include <elm/PreIterator.h>
25 #include <elm/inhstruct/Tree.h>
35 inline const T&
data(
void)
const {
return _value; }
36 inline T&
data(
void) {
return _value; }
54 inline operator bool(
void)
const
63 inline const T&
item(
void)
const {
return static_cast<Tree *
>(it.
item())->_value; }
68 inline operator T()
const {
return item(); }
69 inline operator Tree *()
const {
return item(); }
90 template <
class TT>
void addAll(
const TT& coll)
Tree * operator*() const
Definition: Tree.h:70
Tree * operator->() const
Definition: Tree.h:71
Iter(const Iter &iter)
Definition: Tree.h:61
Iter operator++(int)
Definition: Tree.h:73
bool equals(Iter i) const
Definition: Tree.h:65
void next(void)
Definition: Tree.h:64
Iter(const Tree *tree)
Definition: Tree.h:60
bool operator!=(Iter i) const
Definition: Tree.h:75
const T & item(void) const
Definition: Tree.h:63
bool operator==(Iter i) const
Definition: Tree.h:74
bool ended(void) const
Definition: Tree.h:62
Iter & operator++()
Definition: Tree.h:72
void addSibling(Tree *newSibling)
Definition: Tree.h:86
void removeAll(const TT &coll)
Definition: Tree.h:98
Tree * sibling(void)
Definition: Tree.h:45
Tree(const T &value)
Definition: Tree.h:33
void remove(Tree *child)
Definition: Tree.h:94
void addAll(const TT &coll)
Definition: Tree.h:90
void removeChild(Tree *child)
Definition: Tree.h:92
const Tree * sibling(void) const
Definition: Tree.h:43
void prependChild(Tree *child)
Definition: Tree.h:82
const Tree * children(void) const
Definition: Tree.h:39
int count(void) const
Definition: Tree.h:50
T & data(void)
Definition: Tree.h:36
Tree * children(void)
Definition: Tree.h:41
void remove(const Iter &iter)
Definition: Tree.h:96
bool hasChild(Tree *tree) const
Definition: Tree.h:47
void add(Tree *child)
Definition: Tree.h:88
const T & data(void) const
Definition: Tree.h:35
bool contains(Tree *tree) const
Definition: Tree.h:49
void appendChild(Tree *child)
Definition: Tree.h:84
void clear(void)
Definition: Tree.h:100
bool isEmpty(void) const
Definition: Tree.h:52
bool equals(Iter ii) const
Definition: Tree.h:53
void next(void)
Definition: Tree.h:52
Tree * item(void) const
Definition: Tree.h:51
bool ended(void) const
Definition: Tree.h:50
void addSibling(Tree *newSibling)
Definition: Tree.h:75
void removeAll(const TT &coll)
Definition: Tree.h:87
void remove(Tree *child)
Definition: Tree.h:85
void prependChild(Tree *child)
Definition: Tree.h:68
void addAll(const TT &coll)
Definition: Tree.h:82
Tree * children(void) const
Definition: Tree.h:37
Tree * sibling(void) const
Definition: Tree.h:38
void removeChild(Tree *child)
Definition: inhstruct_Tree.cpp:145
int count(void) const
Definition: inhstruct_Tree.cpp:76
bool hasChild(Tree *tree) const
Definition: Tree.h:39
void add(Tree *child)
Definition: Tree.h:81
void appendChild(Tree *child)
Definition: inhstruct_Tree.cpp:115
void clear(void)
Definition: Tree.h:89
bool isEmpty(void) const
Definition: Tree.h:42
Definition: util_WAHVector.cpp:157