+/******************************************************************************/
+
+/**
+ * Iterator over all children of a node.
+ *
+ * @param cls Closure.
+ * @param peer_id Short ID of the peer.
+ */
+typedef void (*MeshTreeCallback) (void *cls, GNUNET_PEER_Id peer_id);
+
+
+/**
+ * Iterator over all nodes in a tree.
+ *
+ * @param cls Closure.
+ * @param peer_id Short ID of the peer.
+ * @param peer_id Short ID of the parent of the peer.
+ */
+typedef void (*MeshWholeTreeCallback) (void *cls,
+ GNUNET_PEER_Id peer_id,
+ GNUNET_PEER_Id parent_id);
+
+/**
+ * Create a new tunnel tree associated to a tunnel
+ *
+ * @param peer A short peer id of the root of the tree
+ *
+ * @return A newly allocated and initialized tunnel tree
+ */
+struct MeshTunnelTree *
+tree_new (GNUNET_PEER_Id peer);
+
+
+/**
+ * Set the status of a node.
+ *
+ * @param tree Tree.
+ * @param peer A short peer id of the node.
+ * @param status New status to set.
+ */
+void
+tree_set_status (struct MeshTunnelTree *tree, GNUNET_PEER_Id peer,
+ enum MeshPeerState status);
+
+
+/**
+ * Get the status of a node.
+ *
+ * @param tree Tree whose local id we want to now.
+ * @param peer A short peer id of the node.
+ *
+ * @return Short peer id of local peer.
+ */
+enum MeshPeerState
+tree_get_status (struct MeshTunnelTree *tree, GNUNET_PEER_Id peer);
+
+
+/**
+ * Get the id of the predecessor of the local node.
+ *
+ * @param tree Tree whose local id we want to now.
+ *
+ * @return Short peer id of local peer.
+ */
+GNUNET_PEER_Id
+tree_get_predecessor (struct MeshTunnelTree *tree);
+
+