The ptree_add_node() function adds the node specified by handle chdh as a child node to the node specified by the handle parh. PICL_CANTPARENT is if the child node already has a parent.
The ptree_delete_node() function deletes the node specified by handle nodeh and all its descendant nodes from the tree.