eyBuildLib API Reference : eyBuildLib

ebxmldom

NAME

ebxmldom - XML document object model library

ROUTINES

DOMPrintTree( ) - format a DOM tree and write into a stream
DOMWriteTree( ) - format a DOM tree and write into a stream
DOMWriteDocument( ) - format a DOM document and write into a stream
DOMWriteTreeToBuffer( ) - format a DOM tree and write into a buffer
DOMWriteTreeToBuffer( ) - format a DOM tree and write into a buffer
DOMGetRootElement( ) - get the root element of DOM tree
DOMGetElementByTagName( ) - find the element by tag name
DOMGetNextElementByTagName( ) - find the next element by tag name
DOMGetElementByAttribute( ) - find the next element by attribute
DOMGetNextElementByAttribute( ) - find the next element by attribute
DOMCreate( ) - create a DOM object
DOMDestroy( ) - destroy the DOM object
DOMParseFile( ) - parase XML file and generate a DOM tree.
DOMParseBuffer( ) - parase the XML data in pbuf and add into DOM tree
DOMGetLastError( ) - get the last parsing error
DOMGetCurrentLineNumber( ) - get the last line number when parsing error
DOMGetDocumentVersion( ) - get the XML document version
DOMSetDocumentVersion( ) - get the XML document version
DOMGetDocumentEncoding( ) - get the XML document encoding
DOMSetDocumentEncoding( ) - get the XML document encoding
DOMGetDocumentStandalone( ) - get the XML document is standalone or not
DOMSetDocumentStandalone( ) - set the XML document is standalone or not
DOMDeleteElement( ) - unlink a element or a sub tree from DOM tree.
DOMFreeElement( ) - free element and its children elements in a DOM tree.
DOMElementGetAttribute( ) - get attribute by element attribute name
DOMElementGetAttributeByIndex( ) - get attribute by attribute index
DOMElementGetAttributeNumber( ) - get the number of attributes
DOMElementGetTagName( ) - get the tag name of current element
DOMElementGetText( ) - get the content of current element
DOMElementSetText( ) - change the content text of current element
DOMElementSetCDataText( ) - change the content text of current element
DOMElementDeleteAttribute( ) - delete an attribute for current element
DOMElementSetAttribute( ) - change the attribute for current element
DOMElementIsComment( ) - detect current element is comment or not
DOMElementGetComment( ) - get the comment of current element
DOMElementSetComment( ) - set the comment string for current element
DOMCreateRootElement( ) - create a root element for DOM tree
DOMNewElement( ) - create a new element
DOMDupElement( ) - duplicate an element, exclude the chirdren elements
DOMEvalBuffer( ) - evaluate the XML content of a buffer
DOMCreateElementByPath( ) - recursive create XML elements by path
DOMCreateByPath( ) - recursive create XML elements by path
DOMGetElementByPath( ) - get an XML element by path
DOMGetElementsByPath( ) - get elements in the same layer of DOM tree by path
DOMElementGetTextByPath( ) - get the text of the XML element by path
DOMElementGetAttributeByPath( ) - get the attribute of the XML element by path
DOMElementSetTextByPath( ) - set the text of the XML element by path
DOMElementSetCDataTextByPath( ) - change the text of the XML element by path
DOMElementSetAttributeByPath( ) - chage the attribute of the XML element by path

DESCRIPTION

This library is base on expat XML parser.


eyBuildLib : Routines

DOMPrintTree( )

NAME

DOMPrintTree( ) - format a DOM tree and write into a stream

SYNOPSIS

int DOMPrintTree
    (
    DOM_ELEMENT * pnode,
    FILE *        fp
    )

DESCRIPTION

This routine formats a DOM tree and write into a stream

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMWriteTree( )

NAME

DOMWriteTree( ) - format a DOM tree and write into a stream

SYNOPSIS

int DOMWriteTree
    (
    DOM_ELEMENT * pnode,
    DOM_FWRITE    fun_fwrite,
    void *        fp
    )

DESCRIPTION

This routine format a DOM tree and write into a stream with specific callback.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMWriteDocument( )

NAME

DOMWriteDocument( ) - format a DOM document and write into a stream

SYNOPSIS

int DOMWriteDocument
    (
    XML_DOM *  pdom,
    DOM_FWRITE fun_fwrite,
    void *     fp
    )

DESCRIPTION

This routine format a DOM tree and write into a stream with specific callback.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMWriteTreeToBuffer( )

NAME

DOMWriteTreeToBuffer( ) - format a DOM tree and write into a buffer

SYNOPSIS

int DOMWriteTreeToBuffer
    (
    DOM_ELEMENT * pnode,
    char * *      ppbuf,
    size_t        buf_size
    )

DESCRIPTION

This routine format a DOM tree and write into a buffer. If the value of *ppbuf is NULL, it will allocate a new buffer in internal.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMWriteTreeToBuffer( )

NAME

DOMWriteTreeToBuffer( ) - format a DOM tree and write into a buffer

SYNOPSIS

int DOMWriteDocumentToBuffer
    (
    XML_DOM * pdom,
    char * *  ppbuf,
    size_t    buf_size
    )

DESCRIPTION

This routine format a DOM tree and write into a buffer. If the value of *ppbuf is NULL, it will allocate a new buffer in internal.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetRootElement( )

NAME

DOMGetRootElement( ) - get the root element of DOM tree

SYNOPSIS

DOM_ELEMENT * DOMGetRootElement
    (
    XML_DOM * pdom
    )

DESCRIPTION

This routine is to gets the root element of DOM tree.

RETURNS

pointer to the root element of DOM tree.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetElementByTagName( )

NAME

DOMGetElementByTagName( ) - find the element by tag name

SYNOPSIS

DOM_ELEMENT * DOMGetElementByTagName
    (
    DOM_ELEMENT * pnode,
    const char *  tagname
    )

DESCRIPTION

This routine is to find the element by tag name from current node in the DOM tree.

RETURNS

the element or NULL if not found

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetNextElementByTagName( )

NAME

DOMGetNextElementByTagName( ) - find the next element by tag name

SYNOPSIS

DOM_ELEMENT * DOMGetNextElementByTagName
    (
    DOM_ELEMENT * pnode,
    const char *  tagname
    )

DESCRIPTION

This routine is to find the next element by tag name from current node in the DOM tree.

RETURNS

the element or NULL if not found

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetElementByAttribute( )

NAME

DOMGetElementByAttribute( ) - find the next element by attribute

SYNOPSIS

DOM_ELEMENT * DOMGetElementByAttribute
    (
    DOM_ELEMENT * pnode,
    const char *  attrname,   /* attribute name */
    const char *  attrvalue   /* attribute value */
    )

DESCRIPTION

This routine is to find the next element by attribute from current node in the DOM tree.

RETURNS

the element or NULL if not found

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetNextElementByAttribute( )

NAME

DOMGetNextElementByAttribute( ) - find the next element by attribute

SYNOPSIS

DOM_ELEMENT * DOMGetNextElementByAttribute
    (
    DOM_ELEMENT * pnode,
    const char *  attrname,   /* attribute name */
    const char *  attrvalue   /* attribute value */
    )

DESCRIPTION

This routine is to find the next element by element attribute from current node in the DOM tree.

RETURNS

the element or NULL if not found

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMCreate( )

NAME

DOMCreate( ) - create a DOM object

SYNOPSIS

XML_DOM * DOMCreate
    (
    const char * encoding
    )

DESCRIPTION

This routine is to create a DOM object with specific encoding. The encoding may be NULL, UTF-8, ISO-8859-1, US-ASCII, or ANSI.

RETURNS

pointer to the DOM object, or NULL if error occur.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMDestroy( )

NAME

DOMDestroy( ) - destroy the DOM object

SYNOPSIS

int DOMDestroy
    (
    XML_DOM * pdom
    )

DESCRIPTION

This routine will free all the conent of the DOM object.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMParseFile( )

NAME

DOMParseFile( ) - parase XML file and generate a DOM tree.

SYNOPSIS

int DOMParseFile
    (
    XML_DOM * pdom,
    FILE *    fp
    )

DESCRIPTION

This routine is to parase a XML file and generate a DOM tree.

RETURNS

OK, or a error code

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMParseBuffer( )

NAME

DOMParseBuffer( ) - parase the XML data in pbuf and add into DOM tree

SYNOPSIS

int DOMParseBuffer
    (
    XML_DOM *    pdom,        /* DOM object */
    const char * pbuf,        /* data buffer */
    size_t       size,        /* length of data */
    BOOL         done         /* it is last buffer or not */
    )

DESCRIPTION

This routine parase the XML data in pbuf and add into DOM tree, if it is the last buffer, done should be set to TRUE.

RETURNS

OK, or a error code

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetLastError( )

NAME

DOMGetLastError( ) - get the last parsing error

SYNOPSIS

char * DOMGetLastError
    (
    XML_DOM * pdom
    )

DESCRIPTION

This routine is to get the last error message of parsing.

RETURNS

the last error message of parsing.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetCurrentLineNumber( )

NAME

DOMGetCurrentLineNumber( ) - get the last line number when parsing error

SYNOPSIS

size_t DOMGetCurrentLineNumber
    (
    XML_DOM * pdom
    )

DESCRIPTION

This routine is to get the last line number when parsing error.

RETURNS

the last line number message of parsing.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetDocumentVersion( )

NAME

DOMGetDocumentVersion( ) - get the XML document version

SYNOPSIS

char * DOMGetDocumentVersion
    (
    XML_DOM * pdom
    )

DESCRIPTION

This routine is to get the XML document version.

RETURNS

the XML document version, or NULL if not define

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMSetDocumentVersion( )

NAME

DOMSetDocumentVersion( ) - get the XML document version

SYNOPSIS

int DOMSetDocumentVersion
    (
    XML_DOM *    pdom,
    const char * version
    )

DESCRIPTION

This routine is to get the XML document version.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetDocumentEncoding( )

NAME

DOMGetDocumentEncoding( ) - get the XML document encoding

SYNOPSIS

char * DOMGetDocumentEncoding
    (
    XML_DOM * pdom
    )

DESCRIPTION

This routine is to get the XML document encoding.

RETURNS

the XML document encoding, or NULL if not define

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMSetDocumentEncoding( )

NAME

DOMSetDocumentEncoding( ) - get the XML document encoding

SYNOPSIS

int DOMSetDocumentEncoding
    (
    XML_DOM *    pdom,
    const char * encoding
    )

DESCRIPTION

This routine is to get the XML document encoding.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetDocumentStandalone( )

NAME

DOMGetDocumentStandalone( ) - get the XML document is standalone or not

SYNOPSIS

int DOMGetDocumentStandalone
    (
    XML_DOM * pdom
    )

DESCRIPTION

This routine is to get the XML document is standalone or not

RETURNS

TRUE/FALSE

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMSetDocumentStandalone( )

NAME

DOMSetDocumentStandalone( ) - set the XML document is standalone or not

SYNOPSIS

int DOMSetDocumentStandalone
    (
    XML_DOM * pdom,
    BOOL      standalone
    )

DESCRIPTION

This routine is to the XML document is standalone or not.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMDeleteElement( )

NAME

DOMDeleteElement( ) - unlink a element or a sub tree from DOM tree.

SYNOPSIS

int DOMDeleteElement
    (
    XML_DOM *     pdom,
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to unlink a element or a sub tree from DOM tree, It will not free any element. If you want to free a element or a sub tree, you can call DOMFreeElement( ).

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMFreeElement( )

NAME

DOMFreeElement( ) - free element and its children elements in a DOM tree.

SYNOPSIS

int DOMFreeElement
    (
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to free spaces of the element and its children elements in a DOM tree.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetAttribute( )

NAME

DOMElementGetAttribute( ) - get attribute by element attribute name

SYNOPSIS

char * DOMElementGetAttribute
    (
    DOM_ELEMENT * pnode,
    const char *  attrname
    )

DESCRIPTION

This routine is to get attribute by element attribute name.

RETURNS

the attribute or NULL if the attribute is not exist

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetAttributeByIndex( )

NAME

DOMElementGetAttributeByIndex( ) - get attribute by attribute index

SYNOPSIS

char * DOMElementGetAttributeByIndex
    (
    DOM_ELEMENT * pnode,
    size_t        index
    )

DESCRIPTION

This routine is to get attribute by attribute index of element.

RETURNS

the attribute or NULL if the attribute is not exist

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetAttributeNumber( )

NAME

DOMElementGetAttributeNumber( ) - get the number of attributes

SYNOPSIS

int DOMElementGetAttributeNumber
    (
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to get the number of attributes of current element.

RETURNS

the number of attributes

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetTagName( )

NAME

DOMElementGetTagName( ) - get the tag name of current element

SYNOPSIS

char * DOMElementGetTagName
    (
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to get the tag name of current element. If current element is a comment, it will returns a pointer to {comment}.

RETURNS

pointer to the tag name of current element.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetText( )

NAME

DOMElementGetText( ) - get the content of current element

SYNOPSIS

char * DOMElementGetText
    (
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to get the content of current element.

RETURNS

pointer to the content of current element or "".

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementSetText( )

NAME

DOMElementSetText( ) - change the content text of current element

SYNOPSIS

int DOMElementSetText
    (
    DOM_ELEMENT * pnode,
    const char *  text
    )

DESCRIPTION

This routine is to change the content text of current element. If it returns error, it will not change the previous value.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementSetCDataText( )

NAME

DOMElementSetCDataText( ) - change the content text of current element

SYNOPSIS

int DOMElementSetCDataText
    (
    DOM_ELEMENT * pnode,
    const char *  cdata
    )

DESCRIPTION

This routine is to change the content text of current element, the data format will be marked with "".

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementDeleteAttribute( )

NAME

DOMElementDeleteAttribute( ) - delete an attribute for current element

SYNOPSIS

int DOMElementDeleteAttribute
    (
    DOM_ELEMENT * pnode,
    const char *  attrname    /* attribute name */
    )

DESCRIPTION

This routine delete an attribute for current element.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementSetAttribute( )

NAME

DOMElementSetAttribute( ) - change the attribute for current element

SYNOPSIS

int DOMElementSetAttribute
    (
    DOM_ELEMENT * pnode,      /* element */
    const char *  attrname,   /* attribute name */
    const char *  attrvalue   /* attribute value */
    )

DESCRIPTION

This routine changes the attribute for current element. If the attrname is not exist it will try to add a new attribute; if the attrvalue is empty it will remove this attribute.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementIsComment( )

NAME

DOMElementIsComment( ) - detect current element is comment or not

SYNOPSIS

BOOL DOMElementIsComment
    (
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to detect current element is comment or not

RETURNS

TRUE/FALSE

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetComment( )

NAME

DOMElementGetComment( ) - get the comment of current element

SYNOPSIS

char * DOMElementGetComment
    (
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to get the comment of current element.

RETURNS

pointer to comment, or NULL if current element is not a comment

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementSetComment( )

NAME

DOMElementSetComment( ) - set the comment string for current element

SYNOPSIS

int DOMElementSetComment
    (
    DOM_ELEMENT * pnode,
    const char *  comment
    )

DESCRIPTION

This routine is to set the comment string for current element. It will force convert current element into a comment element.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMCreateRootElement( )

NAME

DOMCreateRootElement( ) - create a root element for DOM tree

SYNOPSIS

DOM_ELEMENT * DOMCreateRootElement
    (
    XML_DOM *    pdom,
    const char * tagname
    )

DESCRIPTION

This routine is to create a root element for DOM tree.

RETURNS

pointer to root element, NULL if exists or lack of memory

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMNewElement( )

NAME

DOMNewElement( ) - create a new element

SYNOPSIS

DOM_ELEMENT * DOMNewElement
    (
    const char * tagname,     /* tag name */
    const char * text         /* element text */
    )

DESCRIPTION

This routine is to create a new element.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMDupElement( )

NAME

DOMDupElement( ) - duplicate an element, exclude the chirdren elements

SYNOPSIS

DOM_ELEMENT * DOMDupElement
    (
    DOM_ELEMENT * pnode
    )

DESCRIPTION

This routine is to duplicate an element, it includes the tag name, value and attributes, but exclude the chirdren elements.

RETURNS

OK/ERROR

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMEvalBuffer( )

NAME

DOMEvalBuffer( ) - evaluate the XML content of a buffer

SYNOPSIS

DOM_ELEMENT * DOMEvalBuffer
    (
    const char * encoding,
    const char * pbuf,
    size_t       size
    )

DESCRIPTION

This routine evaluate the XML content of a buffer and return a DOM tree.

RETURNS

pointer to the root node of DOM tree, or NULL if buffer content is not XML format.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMCreateElementByPath( )

NAME

DOMCreateElementByPath( ) - recursive create XML elements by path

SYNOPSIS

int DOMCreateElementByPath
    (
    DOM_ELEMENT * pnode,
    const char *  path
    )

DESCRIPTION

This routine is to recursive create XML elements by path. Path is splited by "/", such as "/xml/element". The element name can include an index, which is start from 0, with [] to create the repeat element, for exmaple "/book[2]/title" is to create the following DOM tree.

<book></book>
<book></book>
<book><title></title></book>

RETURNS

OK, or ERROR if path invalid or lack of memory

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMCreateByPath( )

NAME

DOMCreateByPath( ) - recursive create XML elements by path

SYNOPSIS

int DOMCreateByPath
    (
    XML_DOM *    pdom,
    const char * path
    )

DESCRIPTION

This routine is to recursive create XML elements by path. Path is splited by "/", such as "/xml/element". The element name can include an index, which is start from 0, with [] to create the repeat element, for exmaple "/book[2]/title" is to create the following DOM tree.

<book></book>
<book></book>
<book><title></title></book>

RETURNS

OK, or ERROR if path invalid or lack of memory

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetElementByPath( )

NAME

DOMGetElementByPath( ) - get an XML element by path

SYNOPSIS

DOM_ELEMENT * DOMGetElementByPath
    (
    DOM_ELEMENT * pnode,
    const char *  path
    )

DESCRIPTION

This routine is to get an XML element by path. Path is splited by "/", such as "/xml/element". The element name can include an index, which is start from 0, with [] to get the repeat element, for exmaple "/book[2]/title" is to get the element of the tilte of the third "book3".

<book><title>book1</title></book>
<book><title>book2</title></book>
<book><title>book3</title></book>

RETURNS

pointer to the element, or NULL if no such node.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMGetElementsByPath( )

NAME

DOMGetElementsByPath( ) - get elements in the same layer of DOM tree by path

SYNOPSIS

int DOMGetElementsByPath
    (
    DOM_ELEMENT * pfrom,
    const char *  path,
    DOM_ELEMENT * pdst[],
    size_t        maxnum
    )

DESCRIPTION

This routine is to get elements in the same layer of DOM tree by path, and store the result into the array of pdst, if it is not equals to NULL, at most maxnum elements. Path is splited by "/", such as "/xml/element".

RETURNS

the number of elements be found.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetTextByPath( )

NAME

DOMElementGetTextByPath( ) - get the text of the XML element by path

SYNOPSIS

char * DOMElementGetTextByPath
    (
    DOM_ELEMENT * pnode,
    const char *  path
    )

DESCRIPTION

This routine is to get the text of the XML element by path. Path is splited by "/", such as "/xml/element". The element name can include an index, which is start from 0, with [] to get the repeat element, for exmaple "/book[2]/title" will return the "book3".

<book><title>book1</title></book>
<book><title>book2</title></book>
<book><title>book3</title></book>

RETURNS

pointer to the text of the XML element, or NULL if no such node.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementGetAttributeByPath( )

NAME

DOMElementGetAttributeByPath( ) - get the attribute of the XML element by path

SYNOPSIS

char * DOMElementGetAttributeByPath
    (
    DOM_ELEMENT * pnode,
    const char *  path,
    const char *  attrname
    )

DESCRIPTION

This routine is to get the text of the XML element by path. Path is splited by "/", such as "/xml/element".

RETURNS

pointer to the attribute of the XML element, or NULL if no such node.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementSetTextByPath( )

NAME

DOMElementSetTextByPath( ) - set the text of the XML element by path

SYNOPSIS

int DOMElementSetTextByPath
    (
    DOM_ELEMENT * pnode,
    const char *  path,
    const char *  text
    )

DESCRIPTION

This routine is to set the text of the XML element by path. Path is splited by "/", such as "/xml/element".

RETURNS

OK, or ERROR if no such node or lack of memory.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementSetCDataTextByPath( )

NAME

DOMElementSetCDataTextByPath( ) - change the text of the XML element by path

SYNOPSIS

int DOMElementSetCDataTextByPath
    (
    DOM_ELEMENT * pnode,
    const char *  path,
    const char *  text
    )

DESCRIPTION

This routine is to change the CDATA text of the XML element by path, the data format will be marked with "". Path is splited by "/", such as "/xml/element".

RETURNS

OK, or ERROR if no such node or lack of memory.

SEE ALSO

ebxmldom


eyBuildLib : Routines

DOMElementSetAttributeByPath( )

NAME

DOMElementSetAttributeByPath( ) - chage the attribute of the XML element by path

SYNOPSIS

int DOMElementSetAttributeByPath
    (
    DOM_ELEMENT * pnode,
    const char *  path,
    const char *  attrname,
    const char *  attrvalue
    )

DESCRIPTION

This routine is to change the attribute of the XML element by path. Path is splited by "/", such as "/xml/element".

RETURNS

OK, or ERROR if no such node or lack of memory

SEE ALSO

ebxmldom