29 #include "common/util.h" 43 void Attach(
dgBaseNode *parent,
bool addFirst =
false);
56 const dgBaseNode *Find(dgUnsigned32 nameCRC)
const;
58 const dgBaseNode *Find(
const char *name)
const;
60 void DebugPrint(
const char *fileName);
71 virtual void CloneFixUp(
const dgBaseNode &clone);
72 virtual void PrintHierarchy(dgFile &file,
char *indentation)
const;
88 void Attach(T *parentNode,
bool addFirst =
false);
91 T *GetSibling()
const;
99 T *Find(dgUnsigned32 nameCRC)
const;
100 T *Find(
const char *name)
const;
105 dgRef *CreateClone()
const;
113 inline dgBaseNode::dgBaseNode()
118 inline dgBaseNode::dgBaseNode(
const char *name)
124 inline void dgBaseNode::Clear() {
131 inline dgBaseNode *dgBaseNode::GetChild()
const {
135 inline dgBaseNode *dgBaseNode::GetSibling()
const {
139 inline dgBaseNode *dgBaseNode::GetParent()
const {
144 inline const dgBaseNode *dgBaseNode::Find(
const char *name)
const {
145 return Find(dgCRC(name));
148 inline dgBaseNode *dgBaseNode::Find(
const char *name) {
149 return Find(dgCRC(name));
176 return new T(*const_cast<T *>((
const T *)
this));
181 dgBaseNode::Attach(parentNode, addFirst);
186 dgBaseNode::Detach();
191 return (T *) dgBaseNode::GetChild();
196 return (T *) dgBaseNode::GetSibling();
201 return (T *) dgBaseNode::GetParent();
207 return (T *) dgBaseNode::GetRoot();
213 return (T *) dgBaseNode::GetFirst();
218 return (T *) dgBaseNode::GetLast();
224 return (T *) dgBaseNode::GetNext();
229 return (T *) dgBaseNode::GetPrev();
235 return (T *) dgBaseNode::Find(nameCRC);
240 return (T *) dgBaseNode::Find(name);