Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members  

xmltkobj.h

Go to the documentation of this file.
00001 #ifndef _XMLTKOBJ_H
00002 #define _XMLTKOBJ_H
00003 
00004 ////////////////////////////////////////////////////////////////////////////////
00005 //
00006 // home-grown data types
00007 //
00008 ////////////////////////////////////////////////////////////////////////////////
00009 
00010 typedef unsigned int XTOKEN;
00011 typedef unsigned int UINT;
00012 
00013 #define XST_ELEMENT     0x00
00014 #define XST_ATTRIBUTE   0x01
00015 #define XST_EXTENDEDINT 0x02
00016 #define XST_VALID       (XST_ELEMENT | XST_ATTRIBUTE | XST_EXTENDEDINT)
00017 
00018 #define XT_END          0x00
00019 #define XT_TABLE        0x01
00020 #define XT_STRING       0x02
00021 #define XT_CDATA        0x03
00022 #define XT_UNKNOWN      0x04
00023 
00024 #define XT_FIRST        0x08    // start of range for dynamic (vs hardcoded) tokens
00025 
00026 typedef struct
00027 {
00028     unsigned int uVersion;
00029 }
00030 XBINHEADER, *PXBINHEADER;
00031 
00032 #define XBIN_VERSION    1
00033 
00034 
00035 ////////////////////////////////////////////////////////////////////////////////
00036 //
00037 // interfaces use "COM-Lite"
00038 //
00039 // lightweight, portable interface model inspired by Win32 COM
00040 //
00041 ////////////////////////////////////////////////////////////////////////////////
00042 
00043 
00044 typedef struct
00045 {
00046     unsigned long Data1;
00047     unsigned short Data2;
00048     unsigned short Data3;
00049     unsigned char Data4[8];
00050 }
00051 CLIID, *PCLIID;
00052 
00053 typedef const CLIID*    RCLIID;
00054 
00055 //
00056 // misc required types
00057 //
00058 typedef unsigned long ULONG;
00059 typedef unsigned long DWORD;
00060 typedef int BOOL;
00061 
00062 
00063 #ifdef __cplusplus
00064     #define EXTERN_C    extern "C"
00065 #else
00066     #define EXTERN_C    extern
00067 #endif  // __cplusplus
00068 
00069 
00070 #define CL_STDMETHODIMP            bool 
00071 #define CL_STDMETHODIMP_(type)     type 
00072 
00073 
00074 #define interface               struct
00075 
00076 
00077 
00078 #if defined(__cplusplus) && !defined(CINTERFACE)
00079 
00080 #define CL_STDMETHOD(method)       virtual bool  method
00081 #define CL_STDMETHOD_(type,method) virtual type  method
00082 #define PURE                    = 0
00083 #define THIS_
00084 #define THIS                    void
00085 #define CL_DECLARE_INTERFACE(iface)    interface iface
00086 #define CL_DECLARE_INTERFACE_(iface, baseiface)    interface iface : public baseiface
00087 
00088 
00089 
00090 #else
00091 
00092 #define CL_STDMETHOD(method)       bool ( * method)
00093 #define CL_STDMETHOD_(type,method) type ( * method)
00094 #define PURE
00095 #define THIS_                   CL_INTERFACE *This,
00096 #define THIS                    CL_INTERFACE *This
00097 
00098 #ifdef CONST_VTABLE
00099 #define CL_DECLARE_INTERFACE(iface)    typedef interface iface { \
00100                                     const struct iface##Vtbl * lpVtbl; \
00101                                 } iface; \
00102                                 typedef const struct iface##Vtbl iface##Vtbl; \
00103                                 const struct iface##Vtbl
00104 #else
00105 #define CL_DECLARE_INTERFACE(iface)    typedef interface iface { \
00106                                     struct iface##Vtbl * lpVtbl; \
00107                                 } iface; \
00108                                 typedef struct iface##Vtbl iface##Vtbl; \
00109                                 struct iface##Vtbl
00110 #endif  // CONST_VTABLE
00111 
00112 #define CL_DECLARE_INTERFACE_(iface, baseiface)    CL_DECLARE_INTERFACE(iface)
00113 
00114 
00115 #endif  // defined(__cplusplus) && !defined(CINTERFACE)
00116 
00117 
00118 ////////////////////////////////////////////////////////////////
00119 //
00120 // Some standard interface definitions (including IUnknownCL)
00121 //
00122 ////////////////////////////////////////////////////////////////
00123 
00124 
00125 #undef  CL_INTERFACE
00126 #define CL_INTERFACE   IUnknownCL
00127 
00128 CL_DECLARE_INTERFACE(IUnknownCL)
00129 {
00130     // *** IUnknownCL methods ***
00131     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID rcliid, void **ppvObj) PURE;
00132     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00133     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00134 };
00135 
00136 // {A1D3A5FF-A5BC-46e7-9116-22CF75BBBDE4}
00137 static const CLIID IID_IUnknownCL = 
00138 { 0xa1d3a5ff, 0xa5bc, 0x46e7, { 0x91, 0x16, 0x22, 0xcf, 0x75, 0xbb, 0xbd, 0xe4 } };
00139 
00140 #undef  CL_INTERFACE
00141 #define CL_INTERFACE   IClassFactoryCL
00142 
00143 CL_DECLARE_INTERFACE_(IClassFactoryCL, IUnknownCL)
00144 {
00145     // *** IUnknownCL methods ***
00146     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID rcliid, void **ppvObj) PURE;
00147     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00148     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00149     
00150     // *** IClassFactoryCL methods ***
00151     CL_STDMETHOD(CreateInstance) (THIS_ IUnknownCL **pUnkOuter, CLIID* pid, void **ppvObj) PURE;
00152 };
00153 
00154 // {95488EE9-1269-4cd1-A9A2-6CFDCCBE56FE}
00155 static const CLIID IID_IClassFactoryCL = 
00156 { 0x95488ee9, 0x1269, 0x4cd1, { 0xa9, 0xa2, 0x6c, 0xfd, 0xcc, 0xbe, 0x56, 0xfe } };
00157 
00158 
00159 
00160 #undef  CL_INTERFACE
00161 #define CL_INTERFACE   IObjectWithSiteCL
00162 
00163 CL_DECLARE_INTERFACE_(IObjectWithSiteCL, IUnknownCL)
00164 {
00165     // *** IUnknownCL methods ***
00166     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID rcliid, void **ppvObj) PURE;
00167     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00168     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00169 
00170     // *** IObjectWithSiteCL methods ***
00171     CL_STDMETHOD(SetSite)(THIS_ IUnknownCL *punkSite) PURE;
00172     CL_STDMETHOD(GetSite)(THIS_ CLIID* pid, void **ppvSite) PURE;
00173 };
00174 
00175 // {7D5DF326-2E1E-46fc-A975-3FF31EAAFE6F}
00176 static const CLIID IID_IObjectWithSiteCL = 
00177 { 0x7d5df326, 0x2e1e, 0x46fc, { 0xa9, 0x75, 0x3f, 0xf3, 0x1e, 0xaa, 0xfe, 0x6f } };
00178 
00179 
00180 
00181 #undef  CL_INTERFACE
00182 #define CL_INTERFACE   ITokenTable
00183 
00184 typedef pair<char*, char*>  STRPAIR;
00185 
00186 CL_DECLARE_INTERFACE_(ITokenTable, IUnknownCL)
00187 {
00188     // *** IUnknownCL methods ***
00189     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00190     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00191     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00192 
00193     // *** ITokenTable methods ***
00194     CL_STDMETHOD_(char*, StrFromXTOKEN) (THIS_ XTOKEN xt) PURE;
00195     CL_STDMETHOD_(DWORD, TypeFromXTOKEN) (THIS_ XTOKEN xt) PURE;
00196     CL_STDMETHOD_(STRPAIR*, PairFromXTOKEN) (THIS_ XTOKEN xt) PURE;
00197     CL_STDMETHOD_(XTOKEN, XTOKENFromStr)  (THIS_ char* psz, DWORD dwType) PURE;
00198     CL_STDMETHOD_(XTOKEN, XTOKENFromPair) (THIS_ char* pszFirst, char *pszSecond, DWORD dwType) PURE;
00199 };
00200 
00201 void InitGlobalTokenTable();
00202 void CleanupGlobalTokenTable();
00203 bool GetGlobalTokenTable(RCLIID riid, void** ppv);  // return a pointer to the global token table
00204 
00205 
00206 // {E71FCED6-E2F5-49a2-9191-630155B94CF4}
00207 static const CLIID IID_ITokenTable = 
00208 { 0xe71fced6, 0xe2f5, 0x49a2, { 0x91, 0x91, 0x63, 0x1, 0x55, 0xb9, 0x4c, 0xf4 } };
00209 
00210 
00211 
00212 ////////////////////////////////////////////////////////////////////////////////
00213 //
00214 // ITSAXContentHandler
00215 //
00216 ///////////////////////////////////////////////////////////////////////////////
00217 
00218 
00219 #undef  CL_INTERFACE
00220 #define CL_INTERFACE   ITSAXContentHandler
00221 
00222 CL_DECLARE_INTERFACE_(ITSAXContentHandler, IUnknownCL)
00223 {
00224     // *** IUnknownCL methods ***
00225     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00226     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00227     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00228 
00229     // *** ITSAXContentHandler methods ***
00230     CL_STDMETHOD(startDocument) (THIS) PURE;
00231     CL_STDMETHOD(endDocument) (THIS) PURE;
00232     CL_STDMETHOD(startElement) (THIS_ XTOKEN xtName) PURE;
00233     CL_STDMETHOD(endElement) (THIS_ XTOKEN xtName) PURE;
00234     CL_STDMETHOD(attribute) (THIS_ XTOKEN xtName, char *pszChars, int cchChars) PURE;
00235     CL_STDMETHOD(characters) (THIS_ char *pszChars, int cchChars) PURE;
00236     CL_STDMETHOD(cdata) (THIS_ char *pszChars, int cchChars) PURE;
00237     CL_STDMETHOD(extendedint) (THIS_ XTOKEN xt, int iInt) PURE;
00238 };
00239 
00240 
00241 // {6C25AE7A-1E37-46ea-A2FC-6872E5CC45B8}
00242 static const CLIID IID_ITSAXContentHandler = 
00243 { 0x6c25ae7a, 0x1e37, 0x46ea, { 0xa2, 0xfc, 0x68, 0x72, 0xe5, 0xcc, 0x45, 0xb8 } };
00244 
00245 
00246 
00247 
00248 #undef  CL_INTERFACE
00249 #define CL_INTERFACE    IFilteredTSAXHandler
00250 
00251 class Variable;
00252 
00253 CL_DECLARE_INTERFACE_(IFilteredTSAXHandler, ITSAXContentHandler)
00254 {
00255     // *** IUnknownCL methods ***
00256     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00257     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00258     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00259     
00260     // *** ITSAXContentHandler methods ***
00261     CL_STDMETHOD(startDocument) (THIS) PURE;
00262     CL_STDMETHOD(endDocument) (THIS) PURE;
00263     CL_STDMETHOD(startElement) (THIS_ XTOKEN xtName) PURE;
00264     CL_STDMETHOD(endElement) (THIS_ XTOKEN xtName) PURE;
00265     CL_STDMETHOD(attribute) (THIS_ XTOKEN xtName, char *pszChars, int cchChars) PURE;
00266     CL_STDMETHOD(characters) (THIS_ char *pszChars, int cchChars) PURE;
00267     CL_STDMETHOD(cdata) (THIS_ char *pszChars, int cchChars) PURE;
00268     CL_STDMETHOD(extendedint) (THIS_ XTOKEN xt, int iInt) PURE;
00269 
00270     // *** IFilteredTSAXHandler methods ***
00271     CL_STDMETHOD(startContext) (THIS_ Variable *pv) PURE;
00272     CL_STDMETHOD(endContext) (THIS_ Variable *pv) PURE;
00273 };
00274 
00275 // {08FE5554-A526-4835-A5D8-4ECEEB21D50D}
00276 static const CLIID IID_IFilteredTSAXHandler = 
00277 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0xd } };
00278 
00279 #undef  CL_INTERFACE
00280 #define CL_INTERFACE    IDfaFilter
00281 
00282 CL_DECLARE_INTERFACE_(IDfaFilter, ITSAXContentHandler)
00283 {
00284     // *** IUnknownCL methods ***
00285     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00286     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00287     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00288 
00289     // *** ITSAXContentHandler methods ***
00290     CL_STDMETHOD(startDocument) (THIS) PURE;
00291     CL_STDMETHOD(endDocument) (THIS) PURE;
00292     CL_STDMETHOD(startElement) (THIS_ XTOKEN xtName) PURE;
00293     CL_STDMETHOD(endElement) (THIS_ XTOKEN xtName) PURE;
00294     CL_STDMETHOD(attribute) (THIS_ XTOKEN xtName, char *pszChars, int cchChars) PURE;
00295     CL_STDMETHOD(characters) (THIS_ char *pszChars, int cchChars) PURE;
00296     CL_STDMETHOD(cdata) (THIS_ char *pszChars, int cchChars) PURE;
00297     CL_STDMETHOD(extendedint) (THIS_ XTOKEN xt, int iInt) PURE;
00298 
00299     // *** IDfaFilter methods ***
00300     CL_STDMETHOD_(Variable*,RegisterQuery) (THIS_ Variable *pv, char *psz, bool bEvents) PURE;
00301     CL_STDMETHOD(RegisterQueryFile) (THIS_ char *psz) PURE;
00302 };
00303 
00304 // {08FE5554-A526-4835-A5D8-4ECEEB21D50C}
00305 static const CLIID IID_IDfaFilter = 
00306 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0xc } };
00307 
00308 
00309 
00310 #undef  CL_INTERFACE
00311 #define CL_INTERFACE   ITypeFilter
00312 
00313 
00314 CL_DECLARE_INTERFACE_(ITypeFilter, ITSAXContentHandler)
00315 {
00316     // *** IUnknownCL methods ***
00317     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00318     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00319     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00320     
00321     // *** ITSAXContentHandler methods ***
00322     CL_STDMETHOD(startDocument) (THIS) PURE;
00323     CL_STDMETHOD(endDocument) (THIS) PURE;
00324     CL_STDMETHOD(startElement) (THIS_ XTOKEN xtName) PURE;
00325     CL_STDMETHOD(endElement) (THIS_ XTOKEN xtName) PURE;
00326     CL_STDMETHOD(attribute) (THIS_ XTOKEN xtName, char *pszChars, int cchChars) PURE;
00327     CL_STDMETHOD(characters) (THIS_ char *pszChars, int cchChars) PURE;
00328     CL_STDMETHOD(cdata) (THIS_ char *pszChars, int cchChars) PURE;
00329     CL_STDMETHOD(extendedint) (THIS_ XTOKEN xt, int iInt) PURE;
00330 
00331     // *** ITypeFilter methods ***
00332     CL_STDMETHOD(RegisterType) (THIS_ char *pszType) PURE;
00333 };
00334 
00335 // {808EA8E8-4DB3-4729-9DDD-11BCBCE9A046}
00336 static const CLIID IID_ITypeFilter = 
00337 { 0x808ea8e8, 0x4db3, 0x4729, { 0x9d, 0xdd, 0x11, 0xbc, 0xbc, 0xe9, 0xa0, 0x46 } };
00338 
00339 #undef  CL_INTERFACE
00340 #define CL_INTERFACE    ISetHandler
00341 
00342 CL_DECLARE_INTERFACE_(ISetHandler, IUnknownCL)
00343 {
00344     // *** IUnknownCL methods ***
00345     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00346     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00347     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00348 
00349     // *** ISetHandler methods ***
00350     CL_STDMETHOD(SetHandler) (THIS_ IUnknownCL *punk) PURE;
00351 };
00352 
00353 // {08FE4534-A526-4835-A5D8-4ECEEB21D50F}
00354 static const CLIID IID_ISetHandler = 
00355 { 0x8fe4534, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0xf } };
00356 
00357 #undef  CL_INTERFACE
00358 #define CL_INTERFACE    IStream
00359 
00360 CL_DECLARE_INTERFACE_(IStream, IUnknownCL)
00361 {
00362     // *** IUnknownCL methods ***
00363     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00364     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00365     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00366 
00367     // *** IStream methods ***
00368     CL_STDMETHOD_(long, CopyTo) (THIS_ IStream *pstm, long cb) PURE;
00369     CL_STDMETHOD_(long, Peek) (THIS_ void *pv, long cb) PURE;
00370     CL_STDMETHOD_(long, Read) (THIS_ void *pv, long cb) PURE;
00371     CL_STDMETHOD_(int, ReadChar) (THIS) PURE;
00372     CL_STDMETHOD_(int, Seek) (THIS_ long offset, int origin) PURE;
00373     CL_STDMETHOD_(long, SetSize) (THIS_ long lsize) PURE;
00374     CL_STDMETHOD_(long, Tell) (THIS) PURE;
00375     CL_STDMETHOD_(long, Write) (THIS_ void *pv, long cb) PURE;
00376     CL_STDMETHOD(WriteChar) (THIS_ int ch) PURE;
00377 };
00378 
00379 // {08FE5554-A526-4835-A5D8-4ECEEB21D50D}
00380 static const CLIID IID_IStream = 
00381 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0xd } };
00382 
00383 #undef  CL_INTERFACE
00384 #define CL_INTERFACE    IFileStream
00385 
00386 CL_DECLARE_INTERFACE_(IFileStream, IStream)
00387 {
00388     // *** IUnknownCL methods ***
00389     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00390     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00391     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00392 
00393     // *** IStream methods ***
00394     CL_STDMETHOD_(long, CopyTo) (THIS_ IStream *pstm, long cb) PURE;
00395     CL_STDMETHOD_(long, Peek) (THIS_ void *pv, long cb) PURE;
00396     CL_STDMETHOD_(long, Read) (THIS_ void *pv, long cb) PURE;
00397     CL_STDMETHOD_(int, ReadChar) (THIS) PURE;
00398     CL_STDMETHOD_(int, Seek) (THIS_ long offset, int origin) PURE;
00399     CL_STDMETHOD_(long, SetSize) (THIS_ long lsize) PURE;
00400     CL_STDMETHOD_(long, Tell) (THIS) PURE;
00401     CL_STDMETHOD_(long, Write) (THIS_ void *pv, long cb) PURE;
00402     CL_STDMETHOD(WriteChar) (THIS_ int ch) PURE;
00403 
00404     // *** IFileStream methods ***
00405     CL_STDMETHOD_(int, CloseFile) (THIS) PURE;
00406     CL_STDMETHOD_(FILE*, GetFile) (THIS) PURE;
00407     CL_STDMETHOD(SetFile) (THIS_ FILE *pfile) PURE;
00408     CL_STDMETHOD_(char*, GetFileName) (THIS) PURE;
00409     CL_STDMETHOD(OpenFile) (char *pszFile, char *pszMode) PURE;
00410 };
00411 
00412 // {08FE5554-A526-4835-A5D8-4ECEEB21D510}
00413 static const CLIID IID_IFileStream = 
00414 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0x10 } };
00415 
00416 #undef  CL_INTERFACE
00417 #define CL_INTERFACE    IMemoryStream
00418 
00419 CL_DECLARE_INTERFACE_(IMemoryStream, IStream)
00420 {
00421     // *** IUnknownCL methods ***
00422     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00423     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00424     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00425 
00426     // *** IStream methods ***
00427     CL_STDMETHOD_(long, CopyTo) (THIS_ IStream *pstm, long cb) PURE;
00428     CL_STDMETHOD_(long, Peek) (THIS_ void *pv, long cb) PURE;
00429     CL_STDMETHOD_(long, Read) (THIS_ void *pv, long cb) PURE;
00430     CL_STDMETHOD_(int, ReadChar) (THIS) PURE;
00431     CL_STDMETHOD_(int, Seek) (THIS_ long offset, int origin) PURE;
00432     CL_STDMETHOD_(long, SetSize) (THIS_ long lsize) PURE;
00433     CL_STDMETHOD_(long, Tell) (THIS) PURE;
00434     CL_STDMETHOD_(long, Write) (THIS_ void *pv, long cb) PURE;
00435     CL_STDMETHOD(WriteChar) (THIS_ int ch) PURE;
00436 
00437     // *** IMemoryStream methods ***
00438     CL_STDMETHOD_(int, getSize) (THIS) PURE;
00439     CL_STDMETHOD_(char*, getBuffer) (THIS) PURE;
00440     CL_STDMETHOD(setBuffer) (THIS_ void *pv, int iSize) PURE;
00441     CL_STDMETHOD_(int, getGrowSize) (THIS) PURE;
00442     CL_STDMETHOD(setGrowSize) (THIS_ int cchGrow) PURE;
00443 };
00444 
00445 // {08FE5554-A526-4835-A5D8-4ECEEB21D50E}
00446 static const CLIID IID_IMemoryStream = 
00447 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0xe } };
00448 
00449 #undef  CL_INTERFACE
00450 #define CL_INTERFACE   IParse2TSAX
00451 
00452 
00453 CL_DECLARE_INTERFACE_(IParse2TSAX, IUnknownCL)
00454 {
00455     // *** IUnknownCL methods ***
00456     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00457     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00458     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00459 
00460     // *** IParse2TSAX methods ***
00461     CL_STDMETHOD(Parse) (THIS_ IStream *pstm, ITSAXContentHandler *pch) PURE;
00462     CL_STDMETHOD_(unsigned int,getSrcOffset) (THIS_) PURE;
00463     CL_STDMETHOD(skipReader) (THIS_ unsigned int skipOffset, unsigned int skipLevel) PURE;
00464 };
00465 
00466 // {08FE5554-A526-4835-A5D8-4ECEEB21D50B}
00467 static const CLIID IID_IParse2TSAX = 
00468 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0xb } };
00469 
00470 
00471 #undef  CL_INTERFACE
00472 #define CL_INTERFACE    IBin2TSAX
00473 
00474 CL_DECLARE_INTERFACE_(IBin2TSAX, IParse2TSAX)
00475 {
00476     // *** IUnknownCL methods ***
00477     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00478     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00479     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00480 
00481     // *** IParse2TSAX methods ***
00482     CL_STDMETHOD(Parse) (THIS_ IStream *pstm, ITSAXContentHandler *pch) PURE;
00483     
00484     // *** IBin2TSAX methods ***
00485     CL_STDMETHOD(Init) (THIS_ bool bExternalStream) PURE;
00486 };
00487 
00488 // {08FE5554-A526-4835-A5D8-4ECEEB21D511}
00489 static const CLIID IID_IBin2TSAX = 
00490 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0x11 } };
00491 
00492 
00493 #undef  CL_INTERFACE
00494 #define CL_INTERFACE    ITSAX2Bin
00495 
00496 CL_DECLARE_INTERFACE_(ITSAX2Bin, ITSAXContentHandler)
00497 {
00498     // *** IUnknownCL methods ***
00499     CL_STDMETHOD(QueryInterface) (THIS_ RCLIID riid, void **ppvObj) PURE;
00500     CL_STDMETHOD_(ULONG,AddRef) (THIS) PURE;
00501     CL_STDMETHOD_(ULONG,Release) (THIS) PURE;
00502 
00503     // *** ITSAXContentHandler methods ***
00504     CL_STDMETHOD(startDocument) (THIS) PURE;
00505     CL_STDMETHOD(endDocument) (THIS) PURE;
00506     CL_STDMETHOD(startElement) (THIS_ XTOKEN xtName) PURE;
00507     CL_STDMETHOD(endElement) (THIS_ XTOKEN xtName) PURE;
00508     CL_STDMETHOD(attribute) (THIS_ XTOKEN xtName, char *pszChars, int cchChars) PURE;
00509     CL_STDMETHOD(characters) (THIS_ char *pszChars, int cchChars) PURE;
00510     CL_STDMETHOD(cdata) (THIS_ char *pszChars, int cchChars) PURE;
00511     CL_STDMETHOD(extendedint) (THIS_ XTOKEN xt, int iInt) PURE;
00512 
00513     // *** ITSAX2Bin methods ***
00514     CL_STDMETHOD(Init) (THIS_ IStream* pws, bool bEmitTableEntries) PURE;
00515 };
00516 
00517 // {08FE5554-A526-4835-A5D8-4ECEEB21D50F}
00518 static const CLIID IID_ITSAX2Bin = 
00519 { 0x8fe5554, 0xa526, 0x4835, { 0xa5, 0xd8, 0x4e, 0xce, 0xeb, 0x21, 0xd5, 0xf } };
00520 
00521 
00522 #endif  // _XMLTKOBJ_H
00523 

Generated on Sat Dec 22 16:01:53 2001 for XMILLforBinaryFormat by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001