Next: void F_getChild(parentNodePtrnodeWantedPtr,int index) Up: Nonmember Functions Previous: void F_createTree(nodePtr)

void F_addChild(parentNodePtr,newNodePtr)

A new child is added to the parent node, and a pointer to the new child is returned in newNodePtr. The type of newNodePtr is checked and the new child is of the appropriate type.

The following code creates a new tree and adds an erp child below the top level node.


eventNode *ev;
erpNode *erpPtr;

F_createTree(ev);
F_addChild(ev,erpPtr);


walter@
Wed Aug 10 11:53:26 PDT 1994