XmlEngXPathUtils Class Reference
#include
<xml/dom/xmlengxpathutils.h>
Detailed Description
Implements utility functions such as conversion methods for XPath objects.
The XPath specification considers a node result as a set of only one node, however, in this API it is possible to perform conversion routines directly on nodes.
Member Function Documentation
ToBoolean ( const TXmlEngNode & )
Converts a node to a TBool
Parameters |
---|
aNode | Node to be converted |
- Return Value
- ETrue if the node is not NULL, EFalse otherwise
ToBoolean ( const RXmlEngNodeSet & )
Converts a node-set to a TBool
Parameters |
---|
aNodeSet | Node-set to be converted |
- Return Value
- ETrue if the nodeset is not NULL, EFalse otherwise
ToBoolean ( const TDesC8 & )
Converts a string to a TBool
Parameters |
---|
aValue | String that should be converted |
- Return Value
- ETrue if the string is not an empty string, EFalse otherwise
ToBoolean ( TReal )
Converts a TReal value to a TBool
Parameters |
---|
aValue | TReal value to be converted |
- Return Value
- EFalse if aValue is NaN or 0.0, ETrue otherwise
ToBooleanL ( const TDesC8 & )
Converts a string to a TBool DeprecatedThis function is deprecated and will be removed in future releases.
ToBoolean() should be used instead.
Parameters |
---|
aValue | String that should be converted |
- Return Value
- ETrue if the string is not an empty string, EFalse otherwise
ToNumberL ( const TXmlEngNode & )
Parameters |
---|
aNode | Node to be converted |
- Return Value
- The number represented by the node or NaN if cannot convert.
Leave Codes |
---|
KErrNoMemory | Memory allocation failure |
ToNumberL ( const RXmlEngNodeSet & )
Converts a node-set to a number by taking the node in the node set that appears first in the document and converting that to a number.
Parameters |
---|
aNodeSet | Node-set to be converted |
- Return Value
- The number represented by the node set or NaN if cannot convert.
Leave Codes |
---|
KErrNoMemory | Memory allocation failure |
ToNumberL ( TBool )
Converts TBool value to TReal
Parameters |
---|
aValue | TBool value to be converted |
- Return Value
- 1.0 if ETrue and 0.0 otherwise
ToNumberL ( const TDesC8 & )
Converts a string to a number
Parameters |
---|
aString | String to be converted |
- Return Value
- The number respresented by the string or NaN if cannot convert.
Leave Codes |
---|
KErrNoMemory | Memory allocation failure |
ToStringL ( const TXmlEngNode &, RBuf8 & )
Converts a node to a string. Any existing text in aOutput is destroyed. This method allocates memory for the buffer.
Parameters |
---|
aNode | The node to be converted |
aOutput | A buffer owned by the caller that holds the returned string |
Leave Codes |
---|
KErrNoMemory | Memory allocation failure |
ToStringL ( const RXmlEngNodeSet &, RBuf8 & )
Converts a node-set to a string by taking the node in the node set that appears first in the document and converting that to a string. Any existing text in aOutput is destroyed. This method allocates memory for the buffer.
Parameters |
---|
aNodeSet | The node-set to be converted |
aOutput | A buffer owned by the caller that holds the returned string |
Leave Codes |
---|
KErrNoMemory | Memory allocation failure |
ToStringL ( TBool, RBuf8 & )
IMPORT_C void | ToStringL | ( | TBool | aValue, |
| RBuf8 & | aOutput |
| ) | [static] |
Converts a TBool value to a string. Any existing text in aOutput is destroyed. This method allocates memory for the buffer.
Parameters |
---|
aValue | The TBool value to be converted |
aOutput | A buffer owned by the caller that holds the returned string. "true" if ETrue and "false" otherwise. |
Leave Codes |
---|
KErrNoMemory | Memory allocation failure |
ToStringL ( TReal, RBuf8 & )
IMPORT_C void | ToStringL | ( | TReal | aValue, |
| RBuf8 & | aOutput |
| ) | [static] |
Converts a TReal value to a string. Any existing text in aOutput is destroyed. This method allocates memory for the buffer.
Parameters |
---|
aValue | The TReal value to be converted |
aOutput | A buffer owned by the caller that holds the returned string. |
Leave Codes |
---|
KErrNoMemory | Memory allocation failure |