ZFFramework
 
Loading...
Searching...
No Matches
ZFXml.h File Reference

DOM XML processing. More...

#include "ZFAlgorithmDef.h"

Go to the source code of this file.

Classes

class  v_ZFXmlType
 xml item type More...
 
class  ZFXmlOutputToken
 token used to output a xml document More...
 
class  v_ZFXmlOutputToken
 type wrapper for ZFTypeId::Value More...
 
class  ZFXml
 xml item that holds the xml DOM More...
 
class  v_ZFXml
 type wrapper for ZFTypeId::Value More...
 

Typedefs

typedef v_ZFXmlType::ZFEnumType ZFXmlType
 see v_ZFXmlType
 

Functions

ZFLIB_ZFAlgorithm zfbool ZFXmlTypeFromStringT (zfauto &ret, const zfchar *src, zfindex srcLen=((zfindex) -1), zfstring *errorHint=zft_zfnull)
 see v_ZFXmlType, return enum object if success
 
ZFLIB_ZFAlgorithm zfbool ZFXmlTypeToStringT (zfstring &ret, v_ZFXmlType *const &value, zfstring *errorHint=zft_zfnull)
 see ZFXmlType, return empty string if error
 
zfstring ZFXmlTypeToString (v_ZFXmlType *const &value, zfstring *errorHint=zft_zfnull)
 see v_ZFXmlType, return empty string if error
 
const zfstringZFTypeId_ZFXmlType (void)
 
ZFLIB_ZFAlgorithm zfbool ZFXmlTypeFromDataT (_ZFP_PropTypeW_ZFXmlType &v, const ZFSerializableData &serializableData, zfstring *outErrorHint=zft_zfnull, ZFSerializableData *outErrorPos=zft_zfnull)
 see ZFTYPEID_DECLARE
 
_ZFP_PropTypeW_ZFXmlType ZFXmlTypeFromData (const ZFSerializableData &serializableData, zfstring *outErrorHint=zft_zfnull, ZFSerializableData *outErrorPos=zft_zfnull)
 see ZFTYPEID_DECLARE
 
ZFLIB_ZFAlgorithm zfbool ZFXmlTypeToDataT (ZFSerializableData &serializableData, _ZFP_PropTypeW_ZFXmlType const &v, zfstring *outErrorHint=zft_zfnull)
 see ZFTYPEID_DECLARE
 
ZFSerializableData ZFXmlTypeToData (_ZFP_PropTypeW_ZFXmlType const &v, zfstring *outErrorHint=zft_zfnull)
 see ZFTYPEID_DECLARE
 
ZFLIB_ZFAlgorithm zfbool ZFXmlTypeFromStringT (_ZFP_PropTypeW_ZFXmlType &v, const zfchar *src, zfindex srcLen=((zfindex) -1), zfstring *errorHint=zft_zfnull)
 util method to convert ZFXmlType from string
 
_ZFP_PropTypeW_ZFXmlType ZFXmlTypeFromString (const zfchar *src, zfindex srcLen=((zfindex) -1), zfstring *errorHint=zft_zfnull)
 util method to convert ZFXmlType from string
 
ZFLIB_ZFAlgorithm zfbool ZFXmlTypeToStringT (zfstring &s, _ZFP_PropTypeW_ZFXmlType const &v, zfstring *errorHint=zft_zfnull)
 util method to convert ZFXmlType to string
 
zfstring ZFXmlTypeToString (_ZFP_PropTypeW_ZFXmlType const &v, zfstring *errorHint=zft_zfnull)
 util method to convert ZFXmlType to string
 
const zfstringZFTypeId_ZFXmlOutputToken (void)
 
ZFXmlOutputTokenZFXmlOutputTokenTrim (void)
 xml output token with trim format
 
void ZFXmlOutputTokenTrim (ZFXmlOutputToken const &v)
 see ZFXmlOutputTokenTrim
 
ZFXmlOutputTokenZFXmlOutputTokenDetail (void)
 xml output token with detailed format
 
void ZFXmlOutputTokenDetail (ZFXmlOutputToken const &v)
 see ZFXmlOutputTokenDetail
 
ZFXmlOutputTokenZFXmlOutputTokenDefault (void)
 default xml output token
 
void ZFXmlOutputTokenDefault (ZFXmlOutputToken const &v)
 see ZFXmlOutputTokenDefault
 
const zfstringZFTypeId_ZFXml (void)
 
ZFLIB_ZFAlgorithm zfbool ZFXmlFromDataT (_ZFP_PropTypeW_ZFXml &v, const ZFSerializableData &serializableData, zfstring *outErrorHint=zft_zfnull, ZFSerializableData *outErrorPos=zft_zfnull)
 see ZFTYPEID_DECLARE
 
_ZFP_PropTypeW_ZFXml ZFXmlFromData (const ZFSerializableData &serializableData, zfstring *outErrorHint=zft_zfnull, ZFSerializableData *outErrorPos=zft_zfnull)
 see ZFTYPEID_DECLARE
 
ZFLIB_ZFAlgorithm zfbool ZFXmlToDataT (ZFSerializableData &serializableData, _ZFP_PropTypeW_ZFXml const &v, zfstring *outErrorHint=zft_zfnull)
 see ZFTYPEID_DECLARE
 
ZFSerializableData ZFXmlToData (_ZFP_PropTypeW_ZFXml const &v, zfstring *outErrorHint=zft_zfnull)
 see ZFTYPEID_DECLARE
 
ZFLIB_ZFAlgorithm zfbool ZFXmlFromStringT (_ZFP_PropTypeW_ZFXml &v, const zfchar *src, zfindex srcLen=((zfindex) -1), zfstring *errorHint=zft_zfnull)
 util method to convert ZFXml from string
 
_ZFP_PropTypeW_ZFXml ZFXmlFromString (const zfchar *src, zfindex srcLen=((zfindex) -1), zfstring *errorHint=zft_zfnull)
 util method to convert ZFXml from string
 
ZFLIB_ZFAlgorithm zfbool ZFXmlToStringT (zfstring &s, _ZFP_PropTypeW_ZFXml const &v, zfstring *errorHint=zft_zfnull)
 util method to convert ZFXml to string
 
zfstring ZFXmlToString (_ZFP_PropTypeW_ZFXml const &v, zfstring *errorHint=zft_zfnull)
 util method to convert ZFXml to string
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlElement (const zfstring &name)
 util to create ZFXml
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlText (const zfstring &value)
 util to create ZFXml
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlComment (const zfstring &value)
 util to create ZFXml
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlDocument ()
 util to create ZFXml
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlDeclaration ()
 util to create ZFXml
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlDocType (const zfstring &value)
 util to create ZFXml
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlPI (const zfstring &name, const zfstring &value)
 util to create ZFXml
 
ZFLIB_ZFAlgorithm ZFXml ZFXmlFromInput (const ZFInput &callback, zfstring *errorHint=(zft_zfnull))
 parse xml document, or return an item with null type if fail
 
ZFLIB_ZFAlgorithm zfbool ZFXmlToOutput (const ZFOutput &output, const ZFXml &xmlItem, const ZFXmlOutputToken &token=(ZFXmlOutputTokenDefault()))
 convert xml to output
 
ZFLIB_ZFAlgorithm zfbool ZFXmlToStringT (zfstring &ret, const ZFXml &xmlItem, const ZFXmlOutputToken &token)
 convert xml to string
 
ZFLIB_ZFAlgorithm zfstring ZFXmlToString (const ZFXml &xmlItem, const ZFXmlOutputToken &token)
 see ZFXmlToStringT
 
ZFLIB_ZFAlgorithm void ZFXmlEscapeCharEncode (zfstring &dst, const zfchar *src, zfindex count=(((zfindex) -1)))
 encode xml chars, e.g. convert "&" to "&"
 
ZFLIB_ZFAlgorithm void ZFXmlEscapeCharEncode (const ZFOutput &dst, const zfchar *src, zfindex count=(((zfindex) -1)))
 see ZFXmlEscapeCharEncode
 
ZFLIB_ZFAlgorithm void ZFXmlEscapeCharDecode (zfstring &dst, const zfchar *src, zfindex count=(((zfindex) -1)))
 see ZFXmlEscapeCharEncode
 
ZFLIB_ZFAlgorithm void ZFXmlEscapeCharDecode (const ZFOutput &dst, const zfchar *src, zfindex count=(((zfindex) -1)))
 see ZFXmlEscapeCharEncode
 

Detailed Description

DOM XML processing.

Function Documentation

◆ ZFTypeId_ZFXmlType()

const zfstring & ZFTypeId_ZFXmlType ( void )
inline


◆ ZFTypeId_ZFXmlOutputToken()

const zfstring & ZFTypeId_ZFXmlOutputToken ( void )
inline


◆ ZFTypeId_ZFXml()

const zfstring & ZFTypeId_ZFXml ( void )
inline


◆ ZFXmlToOutput()

ZFLIB_ZFAlgorithm zfbool ZFXmlToOutput ( const ZFOutput & output,
const ZFXml & xmlItem,
const ZFXmlOutputToken & token = (ZFXmlOutputTokenDefault()) )
extern

convert xml to output

Note
result string is not ensured to be a valid xml string if source is not valid

◆ ZFXmlToStringT()

ZFLIB_ZFAlgorithm zfbool ZFXmlToStringT ( zfstring & ret,
const ZFXml & xmlItem,
const ZFXmlOutputToken & token )
extern

convert xml to string

Note
result string is not ensured to be a valid xml string if source is not valid

◆ ZFXmlEscapeCharEncode()

ZFLIB_ZFAlgorithm void ZFXmlEscapeCharEncode ( zfstring & dst,
const zfchar * src,
zfindex count = (((zfindex) -1)) )
extern

encode xml chars, e.g. convert "&" to "&"

support:

&lt; <
&gt; >
&amp; &
&apos; '
&quot; "
&#0; ~ &#65536; decimal encoded char
&#x0; ~ &#xFFFF; heximal encoded char