|
|
Home | Loader API | Interfaces | File List | Index | |
This component represents an element in an XML or JSON document. More...
#include <p6xmlnode.h>
Inherits P6R::p6ICom.
Public Member Functions | |
virtual P6R::P6ERR | addAttribute (const P6WCHAR *pName, P6UINT32 nameLength, const P6WCHAR *pValue, P6UINT32 valueLength, const P6WCHAR *pURI, P6UINT32 uriLength)=0 |
An XML element can have zero or more attributes (e.g., id='5'). | |
virtual P6R::P6ERR | addChild (p6IXMLNode *pNode)=0 |
p6IXMLNode* pLeft->addChild( pNode ), add the pNode parameter as a child of the pLeft p6IXMLNode. | |
virtual P6R::P6INT32 | addref ()=0 |
This method increases the reference count of the component instance by one. | |
virtual P6R::P6ERR | attributeAt (P6UINT32 index, P6GenericAttrib *pAttrib)=0 |
This method allows array style access to the attributes of the current node. | |
virtual P6R::P6ERR | childAt (P6UINT32 index, p6IXMLNode **pChild)=0 |
This method allows array style access to the children of the current node. | |
virtual P6R::P6ERR | getAttribute (const P6WCHAR *pName, P6UINT32 nameLength, P6UINT32 instance, const P6WCHAR **pValue, P6UINT32 *pValueLength, const P6WCHAR **pURI, P6UINT32 *pUriLength)=0 |
Returned the value of an attribute if it is defined in the XML node. | |
virtual P6R::P6ERR | getFloatSortKey (P6FLOAT *pNumber)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | getLocalName (const P6WCHAR **pName, P6UINT32 *pLength)=0 |
Extract out the name of the element, without a namespace prefix, represented by the p6IXMLNode. | |
virtual P6R::P6ERR | getLongSortKey (P6INT64 *pNumber)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | getName (const P6WCHAR **pName, P6UINT32 *pLength)=0 |
Extract out the name of the element, with a namespace prefix if present, represented by the p6IXMLNode. | |
virtual P6R::P6ERR | getNextNamespace (P6UINT32 *pIndex, const P6WCHAR **pName, P6UINT32 *pNameLength, const P6WCHAR **pValue, P6UINT32 *pValueLength)=0 |
Multiple namespaces can be in scope for an XML node. | |
virtual P6R::P6ERR | getNodeId (P6UINT32 *pId)=0 |
Each XML node is give a node id during intialization. | |
virtual P6R::P6ERR | getNumAttributes (P6UINT32 *pCount)=0 |
Returns the number of attributes for the current node. | |
virtual P6R::P6ERR | getNumberSortKey (P6INT32 *pNumber)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | getNumChildren (P6UINT32 *pCount)=0 |
Returns the number of child XML nodes the current node is pointing to in the DOMXML tree. | |
virtual P6R::P6ERR | getParent (p6IXMLNode **pParent)=0 |
To support tree walking, this method returns the parent of the current XML node. | |
virtual P6R::P6ERR | getStringSortKey (const P6WCHAR **pString, P6UINT32 *pLength)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | getTimeSortKey (p6IXpathTime **pTime)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | getType (P6XMLNodeType *pType)=0 |
Returns the type of the node: is it a leaf, a character node, tree root, etc? | |
virtual P6R::P6ERR | getUniqueName (const P6WCHAR **pName, P6UINT32 *pLength)=0 |
Some applications (e.g., XSLT) require that each node in the DOM tree has a unique node identifier. | |
virtual P6R::P6ERR | getURI (const P6WCHAR **pURI, P6UINT32 *pLength)=0 |
Get the namespace URI associated with the XML node represented by the p6IXMLNode. | |
virtual P6R::P6ERR | getValue (const P6WCHAR **pValue, P6UINT32 *pLength)=0 |
Extract the value of the XML node, if present (e.g., <selected/>). | |
virtual P6R::P6ERR | getXpathValue (P6XPATH_ATOMIZED *pValue)=0 |
XPath can define the type of a node. | |
virtual P6R::P6ERR | initialize (P6XMLNODEFLAGS flags, P6XMLNodeType type, P6BOOL bDynamic, P6UINT32 nodeId)=0 |
Sets up the component to run properly. | |
virtual P6R::P6ERR | isChild (const P6WCHAR *pName, P6UINT32 nameLength, P6UINT32 instance, p6IXMLNode **pExist, P6BOOL *pResult)=0 |
There there a child of this XML node with the name of the value in the pName parameter. | |
virtual P6R::P6ERR | isName (const P6WCHAR *pName, P6UINT32 nameLength, const P6WCHAR *pURI, P6UINT32 uriLength, P6BOOL *pResult)=0 |
Test the name of the XML node. | |
virtual P6R::P6ERR | nextAttribute (P6GenericAttrib *pAttrib)=0 |
This method returns the next attribute of the current XML node. | |
virtual P6R::P6ERR | nextChild (p6IXMLNode **pChild)=0 |
This method returns the next child of the current XML node. | |
virtual P6R::P6ERR | outputAsString (p6IDataStream *pStream, P6DOMCHARSET charSet)=0 |
For a node with children this method concatentates all values of each child and writes their values to the stream parameter. | |
virtual P6R::P6ERR | outputSubTree (p6IDataStream *pOutput, P6DOMCHARSET charSet, P6BOOL disableEscaping, P6BOOL omitXMLDecl)=0 |
Write the contents of the subtree rooted at this node in XML format. | |
virtual P6R::P6ERR | outputSubTreeInJSON (p6IDataStream *pOutput, P6DOMCHARSET charSet)=0 |
Write the contents of the subtree rooted at this node in JSON format. | |
virtual P6R::P6ERR | print ()=0 |
Write the contents of the XML Node to a log file defined by the system. | |
virtual P6R::P6ERR | queryInterface (const P6R::IID &iid, P6R::P6VOID **ppIface)=0 |
This method queries the component for a specific interface. | |
virtual P6R::P6INT32 | release ()=0 |
This method decrements a components reference count. | |
virtual P6R::P6ERR | removeChildAt (P6UINT32 index)=0 |
The current node has getNumChildren() number of children. | |
virtual P6R::P6ERR | removeWhiteSpace ()=0 |
Remove all unnecessary white space around the current element node. | |
virtual P6R::P6ERR | resetAttribute ()=0 |
The methods resetAttribute, nextAttribute provide a simple enumerator for all attributes of the current node. | |
virtual P6R::P6ERR | resetChild ()=0 |
The methods resetChild, nextChild provide a simple enumerator for all child XML node of the current node. | |
virtual P6R::P6ERR | setFloatSortKey (P6FLOAT number)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | setLongSortKey (P6INT64 number)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | setName (const P6WCHAR *pName, P6UINT32 length)=0 |
Each p6IXMLNode represents an element in an XML document (e.g., <price>5.00</price>. | |
virtual P6R::P6ERR | setNumberSortKey (P6INT32 number)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | setStringSortKey (const P6WCHAR *pString, P6UINT32 length)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | setTimeSortKey (p6IXpathTime *pTime)=0 |
This method is used to support sorting of p6IXMLNode components in a p6IDOMNodeset container. | |
virtual P6R::P6ERR | setType (P6XMLNodeType type)=0 |
Allows the application to change the type of the node set during initialization. | |
virtual P6R::P6ERR | setURI (const P6WCHAR *pURI, P6UINT32 length)=0 |
Set the namespace URI associated with the XML node represented by the p6IXMLNode. | |
virtual P6R::P6ERR | setValue (const P6WCHAR *pValue, P6UINT32 length)=0 |
Each p6IXMLNode represents an element in an XML document (e.g., <price>5.00lt;/price>. | |
virtual P6R::P6ERR | setXpathValue (P6XPATH_ATOMIZED *pValue)=0 |
XPath can define the type of a node. | |
virtual P6R::P6ERR | toDouble (P6FLOAT *pNumber)=0 |
Convert the contents of the XML node to an double precision floating point value. | |
virtual P6R::P6ERR | toInteger (P6INT32 *pNumber)=0 |
Convert the contents of the XML node to an integer value. | |
virtual P6R::P6ERR | toString (P6WCHAR *pBuffer, P6UINT32 *pLength)=0 |
For a node with children this method concatenates all values of each child into the buffer parameter. |
This component represents an element in an XML or JSON document.
So for example, in the XML document: <book><chapter><title>P6R Progammer's Guide</title></chapter></book>, there would be one p6IXMLNode for "book", and one for "chapter", and one for "title". The title node would be a child of the chapter node. The chapter node would be a child of the book node, thus constructing the P6R::p6IDOMXML tree.
Definition at line 90 of file p6xmlnode.h.