diff options
-rw-r--r-- | common/eurephia_xml.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/common/eurephia_xml.h b/common/eurephia_xml.h index cfa0e60..51ee9dd 100644 --- a/common/eurephia_xml.h +++ b/common/eurephia_xml.h @@ -44,6 +44,14 @@ typedef enum _exmlResultType { exmlRESULT = 1, /**< Operation successful. Additi #ifdef HAVE_LIBXML2 #include <libxml/tree.h> +/** + * Simple iterator macro for iterating xmlNode pointers + * + * @param start Pointer to an xmlNode where to start iterating + * @param itn An xmlNode pointer which will be used for the iteration. + */ +#define foreach_xmlnode(start, itn) for( itn = start; itn != NULL; itn = itn->next ) + char *xmlGetAttrValue(xmlAttr *properties, const char *key); xmlNode *xmlFindNode(xmlNode *node, const char *key); |