From 0c9803cf78453a19ec37fbc2b3fdba3c106cfd84 Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Sun, 29 Dec 2013 15:25:39 +0000 Subject: construct topoligicaly consitant (dependancy correct) interface map use dependancy map to generate javascript prototype for all interfaces in the binding. --- src/nsgenbind-ast.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'src/nsgenbind-ast.h') diff --git a/src/nsgenbind-ast.h b/src/nsgenbind-ast.h index 128dce7..4911f5a 100644 --- a/src/nsgenbind-ast.h +++ b/src/nsgenbind-ast.h @@ -82,12 +82,27 @@ genbind_node_find(struct genbind_node *node, * search the full tree depth (initial search) or the result * of a previous search to continue. * @param nodetype The type of node to seach for + * @return The found node or NULL for no nodes. */ struct genbind_node * genbind_node_find_type(struct genbind_node *node, struct genbind_node *prev, enum genbind_node_type nodetype); +/** count how many nodes of a specified type. + * + * Enumerate how many nodes of the specified type there are by + * performing a depth first search for nodes of the given type and + * counting the number of results. + * + * @param node The node to start the search from + * @param nodetype The type of node to count + * @return The number of nodes found. + */ +int +genbind_node_enumerate_type(struct genbind_node *node, + enum genbind_node_type type); + /** Depth first left hand search returning nodes of the specified type * and a ident child node with matching text * -- cgit v1.2.3