Coconut XML Framework
beta
|
Define XML decode error. More...
#include <Coconut/Coconut.h>
#include <libxml/tree.h>
Go to the source code of this file.
Classes | |
struct | CNXMLDecodeError |
Information for XML decode error. More... | |
Enumerations | |
enum | CNXMLDecodeErrorType { CNXMLNoDecodeError = 0, CNXMLIsNotElementNodeError, CNXMLChildIsNotFoundError, CNXMLInvalidElementNameError, CNXMLNoAttributeNameError, CNXMLInvalidAttributeValueError, CNXMLInvalidContextError } |
Type of XML decode error. More... | |
Functions | |
static CNXMLDecodeErrorType | CNXMLTypeOfDecodeError (const struct CNXMLDecodeError *src) |
Get type in CNXMLDecodeError. | |
static void | CNXMLSetNoDecodeError (struct CNXMLDecodeError *dst) |
Set No decode error. | |
static void | CNXMLSetIsNotElementNodeError (struct CNXMLDecodeError *dst, xmlNodePtr node) |
Set XML is not element node error. | |
static void | CNXMLSetChildIsNotFoundError (struct CNXMLDecodeError *dst, xmlNodePtr node, const xmlChar *reqname) |
Set XML is not element node error. | |
static void | CNXMLSetInvalidElementNameError (struct CNXMLDecodeError *dst, xmlNodePtr node, const xmlChar *reqname) |
Set XML invalid element name error. | |
static void | CNXMLSetNoAttributeNameError (struct CNXMLDecodeError *dst, xmlNodePtr node, const xmlChar *reqname) |
Set XML no attribute name error. | |
static void | CNXMLSetInvalidAttributeValueError (struct CNXMLDecodeError *dst, xmlNodePtr node, const xmlChar *attrname, const xmlChar *invval) |
Set XML invalid attribute value error. | |
static void | CNXMLSetInvalidContextError (struct CNXMLDecodeError *dst, xmlNodePtr node) |
Set XML invalid context error. | |
struct CNString * | CNXMLDecodeErrorToString (const struct CNXMLDecodeError *src, struct CNResource *resource) |
Convert CNXMLDecodeError to error message. |
Define XML decode error.
enum CNXMLDecodeErrorType |
Type of XML decode error.
static CNXMLDecodeErrorType CNXMLTypeOfDecodeError | ( | const struct CNXMLDecodeError * | src | ) | [inline, static] |
Get type in CNXMLDecodeError.
src | Source XML decode error |
References CNXMLDecodeError::errorType.
static void CNXMLSetNoDecodeError | ( | struct CNXMLDecodeError * | dst | ) | [inline, static] |
Set No decode error.
dst | Destination error information |
References CNXMLNoDecodeError, CNXMLDecodeError::errorNode, and CNXMLDecodeError::errorType.
static void CNXMLSetIsNotElementNodeError | ( | struct CNXMLDecodeError * | dst, |
xmlNodePtr | node | ||
) | [inline, static] |
Set XML is not element node error.
dst | Destination error information |
node | XML node whose has this error |
References CNXMLIsNotElementNodeError, CNXMLDecodeError::errorNode, and CNXMLDecodeError::errorType.
static void CNXMLSetChildIsNotFoundError | ( | struct CNXMLDecodeError * | dst, |
xmlNodePtr | node, | ||
const xmlChar * | reqname | ||
) | [inline, static] |
Set XML is not element node error.
dst | Destination error information |
node | XML node whose has this error |
reqname | Target node name |
References CNXMLChildIsNotFoundError, CNXMLDecodeError::context, CNXMLDecodeError::errorNode, and CNXMLDecodeError::errorType.
static void CNXMLSetInvalidElementNameError | ( | struct CNXMLDecodeError * | dst, |
xmlNodePtr | node, | ||
const xmlChar * | reqname | ||
) | [inline, static] |
Set XML invalid element name error.
dst | Destination error information |
node | XML node whose has this error |
reqname | Required element name |
References CNXMLInvalidElementNameError, CNXMLDecodeError::context, CNXMLDecodeError::errorNode, and CNXMLDecodeError::errorType.
static void CNXMLSetNoAttributeNameError | ( | struct CNXMLDecodeError * | dst, |
xmlNodePtr | node, | ||
const xmlChar * | reqname | ||
) | [inline, static] |
Set XML no attribute name error.
dst | Destination error information |
node | XML node whose has this error |
reqname | Required attribute name |
References CNXMLNoAttributeNameError, CNXMLDecodeError::context, CNXMLDecodeError::errorNode, and CNXMLDecodeError::errorType.
static void CNXMLSetInvalidAttributeValueError | ( | struct CNXMLDecodeError * | dst, |
xmlNodePtr | node, | ||
const xmlChar * | attrname, | ||
const xmlChar * | invval | ||
) | [inline, static] |
Set XML invalid attribute value error.
dst | Destination error information |
node | XML node whose has this error |
attrname | Attribute name |
invval | Invalid attribute value |
References CNXMLInvalidAttributeValueError, CNXMLDecodeError::context, CNXMLDecodeError::errorNode, and CNXMLDecodeError::errorType.
static void CNXMLSetInvalidContextError | ( | struct CNXMLDecodeError * | dst, |
xmlNodePtr | node | ||
) | [inline, static] |
Set XML invalid context error.
dst | Destination error information |
node | XML node whose has this error |
References CNXMLInvalidContextError, CNXMLDecodeError::errorNode, and CNXMLDecodeError::errorType.
struct CNString* CNXMLDecodeErrorToString | ( | const struct CNXMLDecodeError * | src, |
struct CNResource * | resource | ||
) | [read] |
Convert CNXMLDecodeError to error message.
src | Source error information |
resource | Resource to allocate error message |