29 #ifndef __HIERARCHY_H__
30 #define __HIERARCHY_H__
40 template<
class type >
76 template<
class type >
89 template<
class type >
91 RemoveFromHierarchy();
101 template<
class type >
113 template<
class type >
123 template<
class type >
125 if ( parent == &node ) {
127 }
else if ( parent ) {
128 return parent->ParentedBy( node );
140 template<
class type >
145 sibling = node.
child;
156 template<
class type >
169 template<
class type >
174 prev = GetPriorSiblingNode();
178 parent->
child = sibling;
193 template<
class type >
209 child->RemoveFromParent();
219 template<
class type >
222 return parent->owner;
232 template<
class type >
245 template<
class type >
248 return sibling->owner;
260 template<
class type >
262 if ( !parent || ( parent->child ==
this ) ) {
269 node = parent->
child;
271 while( ( node !=
this ) && ( node !=
NULL ) ) {
276 if ( node !=
this ) {
277 idLib::Error(
"idHierarchy::GetPriorSibling: could not find node in parent's list of children" );
290 template<
class type >
294 prior = GetPriorSiblingNode();
309 template<
class type >
335 template<
class type >
341 while ( node->
child ) {
352 while ( node->
child ) {
type * GetPriorSibling(void) const
void MakeSiblingAfter(idHierarchy &node)
type * GetNextLeaf(void) const
void SetOwner(type *object)
GLuint GLuint GLsizei GLenum type
void ParentTo(idHierarchy &node)
bool ParentedBy(const idHierarchy &node) const
idHierarchy< type > * GetPriorSiblingNode(void) const
void RemoveFromHierarchy(void)
type * GetNext(void) const
type * GetChild(void) const
type * GetSibling(void) const
type * GetParent(void) const
static void Error(const char *fmt,...)
void RemoveFromParent(void)