Save an XML node tree to an allocated string. This function returns a pointer to a string containing the textual representation of the XML node tree. The string should be freed using the free() function when you are done with it. NULL is returned if the node would produce an empty string or if the string cannot be allocated.
char * mxmlSaveAllocString( mxml_node_t * node, const char * (*cb)(mxml_node_t *node, int ws));
Name | Description |
---|---|
node | Node to write |
(*cb)(mxml_node_t *node, int ws) | Whitespace callback or MXML_NO_CALLBACK |
Allocated string or NULL