#ifndef __SCIP_XML_H__
#define __SCIP_XML_H__
#ifdef __cplusplus
extern "C" {
#endif
typedef struct XML_ATTR_struct XML_ATTR;
struct XML_ATTR_struct
{
char* name;
char* value;
XML_ATTR* next;
};
typedef struct XML_NODE_struct XML_NODE;
struct XML_NODE_struct
{
char* name;
int lineno;
XML_ATTR* attrlist;
XML_NODE* parent;
XML_NODE* prevsibl;
XML_NODE* nextsibl;
XML_NODE* firstchild;
XML_NODE* lastchild;
char* data;
};
XML_NODE* xmlProcess(
const char* filename
);
XML_NODE* xmlNewNode(
const char* name,
int lineno
);
XML_ATTR* xmlNewAttr(
const char* name,
const char* value
);
void xmlAddAttr(
XML_NODE* n,
XML_ATTR* a
);
void xmlAppendChild(
XML_NODE* parent,
XML_NODE* child
);
void xmlFreeNode(
XML_NODE* node
);
void xmlShowNode(
const XML_NODE* root
);
const char* xmlGetAttrval(
const XML_NODE* node,
const char* name
);
const XML_NODE* xmlFirstNode(
const XML_NODE* node,
const char* name
);
const XML_NODE* xmlNextNode(
const XML_NODE* node,
const char* name
);
const XML_NODE* xmlFindNode(
const XML_NODE* node,
const char* name
);
const XML_NODE* xmlFindNodeMaxdepth(
const XML_NODE* node,
const char* name,
int depth,
int maxdepth
);
const XML_NODE* xmlNextSibl(
const XML_NODE* node
);
const XML_NODE* xmlPrevSibl(
const XML_NODE* node
);
const XML_NODE* xmlFirstChild(
const XML_NODE* node
);
const XML_NODE* xmlLastChild(
const XML_NODE* node
);
const char* xmlGetName(
const XML_NODE* node
);
int xmlGetLine(
const XML_NODE* node
);
const char* xmlGetData(
const XML_NODE* node
);
const char* xmlFindPcdata(
const XML_NODE* node,
const char* name
);
#ifdef __cplusplus
}
#endif
#endif