/** * @file XTPPropExchange.h * * @copyright * (c) 1998-2025 Codejock Software, All Rights Reserved. * * This source file is the property of Codejock Software and must not be * redistributed by any means without the explicit written permission of * Codejock Software. * * The use of this source code is governed by the terms and conditions specified * in the Toolkit Pro license agreement. Codejock Software grants you, as a * single software developer, the limited right to use this software on one * computer only. * * Contact Information: * support@codejock.com * http://www.codejock.com * */ /** @cond */ #if !defined(__XTPPROPEXCHANGE_H__) # define __XTPPROPEXCHANGE_H__ /** @endcond */ # if _MSC_VER > 1000 # pragma once # endif // _MSC_VER > 1000 # include "Common/XTPPropExchange.inc" # include "Common/Base/Diagnostic/XTPDisableNoisyWarnings.h" # define XTP_LOCALE_ISO8601 ((LCID)-1) class CXTPPropExchange; class CXTPPropExchangeEnumerator; template class CXTPPoint3T; enum VARTYPE_EX { VT_EX_RECT = 100, VT_EX_SIZE = 101 }; /** * @brief * CXTPPropExchange is standalone pure class. * The CXTPPropExchange class allows you to save a complex network of objects in a permanent * binary or text form (usually disk storage) that persists after those objects are deleted. * Later you can load the objects from persistent storage, reconstituting them in memory. This * process of making data persistent is called 'serialization.' * * You can use one of derived classes: * CXTPPropExchangeArchive to serialize to archive, * CXTPPropExchangeRegistry to serialize to registry key, * CXTPPropExchangeXMLNode to serialize to XML node. * * Example: *
 * CXTPPropExchangeXMLNode px(TRUE, 0, _T(\"Settings\"));
 * if (px.LoadFromFile(m_strIniFileName))
 * {
 *    m_wndTaskPanel.GetGroups()->DoPropExchange(&px);
 * }
 * 
*/ class _XTP_EXT_CLASS CXTPPropExchange : public CXTPCmdTarget { /** @cond */ DECLARE_DYNAMIC(CXTPPropExchange) /** @endcond */ public: /** * @brief * Constructs a CXTPPropExchange object. */ CXTPPropExchange(); /** * @brief * Destroys a CXTPPropExchange object, handles cleanup and de- * allocation. */ virtual ~CXTPPropExchange(); public: /** * @brief * This method determines whether properties are being loaded to * the class or stored from it. * @return * Nonzero if properties are being loaded; otherwise, it is zero. */ BOOL IsLoading() const; /** * @brief * This method determines whether properties are being loaded to * the class or stored from it. * @return * Nonzero if the properties are currently being used for storing; otherwise 0. */ BOOL IsStoring() const; /** * @brief * Call this method to use default values specified in PX_* functions while load process. * @param bUseDefaultOnLoad TRUE to use default value; FALSE to ignore it. * @see * UseDefaultOnSave, PX_String, PX_Int, PX_Bool */ void UseDefaultOnLoad(BOOL bUseDefaultOnLoad = TRUE); /** * @brief * Call this method to use default values specified in PX_* functions while save process. * @param bUseDefaultOnSave TRUE to use default value; FALSE to ignore it. * @see * UseDefaultOnLoad, PX_String, PX_Int, PX_Bool */ void UseDefaultOnSave(BOOL bUseDefaultOnSave = TRUE); /** * @brief * Determines if CXTPPropExchange is used as root section * @return * TRUE if CXTPPropExchange object it root section. * @details * Used only in CXTPPropExchangeXMLNode and CXTPPropExchangeRegistry classes * @see * GetSection */ BOOL IsRootSection() const; /** * @brief * Gets schema version number associated with the data format being * serialized/de-serialized. * @details * Setting a custom schema number requires extreme caution and confidence in the correct * value as using a wrong value will result in unexpected behavior when data exchange is * performed. The current schema version number can be identified by the _XTP_SCHEMA_CURRENT * constant. * @return * The schema version number associated with the data format. */ UINT GetSchema() const; /** * @brief * Sets schema version number associated with the data format being * serialized/de-serialized. * @details * Setting a custom schema number requires extreme caution and confidence in the correct * value as using a wrong value will result in unexpected behavior when data exchange is * performed. The current schema version number can be identified by the _XTP_SCHEMA_CURRENT * constant. * @param nSchemaVersion Identifies the schema version */ void SetSchema(UINT nSchemaVersion); /** * @brief * Exchanges a property between a storage and the class. * @param pszPropName The name of the property being exchanged. * @param vtProp A symbol specifying the type of the property being * exchanged. * @param pvProp A pointer to the property's value. * @param pvDefault Pointer to a default value for the property. * @details * Possible values of properties are: *
	 * Symbol         Property Type
	 * -------------  -------------
	 * VT_I2          short
	 * VT_I4          long
	 * VT_BOOL        BOOL
	 * VT_BSTR        CString
	 * VT_CY          CY
	 * VT_R4          float
	 * VT_R8          double
	 * 
* @return * Nonzero if the exchange was successful; 0 if unsuccessful. */ virtual BOOL ExchangeProp(LPCTSTR pszPropName, VARTYPE vtProp, void* pvProp, const void* pvDefault = NULL) = 0; /** * @brief * This method serializes a property that stores binary large object (BLOB) data. * @param pszPropName The name of the property being exchanged. * @param pData A pointer to a user-supplied buffer that contains the data to be * serialized * @param nBytes An integer that specifies the number of bytes to be read or written. * @return * Nonzero if the exchange was successful; 0 if unsuccessful. */ virtual BOOL ExchangeBlobProp(LPCTSTR pszPropName, BYTE*& pData, DWORD& nBytes); /** * @brief * Exchanges a CRuntimeClass between a storage and the class. * @param pszPropName The name of the property being exchanged. * @param pClass CRuntimeClass class pointer. * @param pDefaultClass Pointer to a default runtime class for the property. * @return * Nonzero if the exchange was successful; 0 if unsuccessful. */ virtual BOOL ExchangeRuntimeClass(LPCTSTR pszPropName, CRuntimeClass*& pClass, CRuntimeClass* pDefaultClass); /** * @brief * Exchanges a class instance. * @param pObject Object being exchanged. * @param pObjectRuntime Default RUntime class of object * @return * Nonzero if the exchange was successful; 0 if unsuccessful. */ virtual BOOL ExchangeObjectInstance(CObject*& pObject, CRuntimeClass* pObjectRuntime); /** * @brief * This method create new Archive to serialize. * @param pszPropName The name of the property being exchanged. * @return * CArchive pointer. You must call ReleaseArchive to free memory. * @see * ReleaseArchive */ virtual CArchive* GetArchive(LPCTSTR pszPropName); /** * @brief * This method releases CArchive pointer. * @param pszPropName The name of the property being exchanged. * @param pArchive Archive pointer was previously returned by GetArchive member. * @see * GetArchive */ virtual void ReleaseArchive(LPCTSTR pszPropName, CArchive* pArchive); /** * @brief * Call this function to serialize or initialize the state of a class's version information */ void ExchangeSchema(); /** * @brief * Call this function to serialize or initialize the state of a user locale */ void ExchangeLocale(); /** * @brief * This method creates new section for text base storages (CXTPPropExchangeXMLNode and * CXTPPropExchangeRegistry) * @param lpszSection The name of the section. * @return * CXTPPropExchange pointer to new section. You must delete this pointer or use * CXTPPropExchangeSection to manage it. * * Example: *
	 * CXTPPropExchangeSection pxTaskPanel(px.GetSection(_T("TaskPanel")));
	 * m_wndTaskPanel.GetGroups()->DoPropExchange(&pxTaskPanel);
	 * 
*/ virtual CXTPPropExchange* GetSection(LPCTSTR lpszSection) = 0; /** * @brief * Call this method to free section information before storing */ virtual void EmptySection(); /** * @brief * Use this member function to Write DWORD number to storage * @param dwCount DWORD number * @see * ReadCount */ virtual void WriteCount(DWORD dwCount); /** * @brief * Use this member function to read DWORD number from storage * @return * DWORD number * @see * WriteCount */ virtual DWORD ReadCount(); /** * @brief * Writes a specified number of bytes. * @param pszPropName The name of the property being exchanged. * @param lpBuf A pointer to a user-supplied buffer that contains the data to be written. * @param nCount An integer that specifies the number of bytes to be written. */ virtual void Write(LPCTSTR pszPropName, const void* lpBuf, UINT nCount); /** * @brief * Reads a specified number of bytes. * @param pszPropName The name of the property being exchanged. * @param lpBuf A pointer to a user-supplied buffer that is to receive the data * @param nCount An unsigned integer specifying the number of bytes to be read from the * archive. * @return * An unsigned integer containing the number of bytes actually read. */ virtual UINT Read(LPCTSTR pszPropName, void* lpBuf, UINT nCount); /** * @brief * Call this method to determine if storage supported default values. * @return * TRUE if storage allows default values */ virtual BOOL IsAllowDefaultValues() const; /** * @brief * Call this method to determine if storage allows exchange plain blob values. * @return * TRUE if storage allows exchange plain blob values. */ virtual BOOL IsAllowBlobValues() const; /** * @brief * This method is called before exchange properties. * @return * TRUE if storage ready to exchange properties. */ virtual BOOL OnBeforeExchange(); /** * @brief * Call this method to enumerate child sections. * @param lpszSection child section name. * @return * Returns an enumerator for child sections. * * Example: *
	 * extern CXTPPropExchange* pPX;
	 *
	 * CXTPPropExchangeEnumeratorPtr pEnumerator(pPX->GetEnumerator(_T("Icon")));
	 * POSITION posEnum = pEnumerator->GetPosition();
	 *
	 * while (posEnum)
	 * {
	 *    CXTPPropExchangeSection secIcon(pEnumerator->GetNext(posEnum));
	 * }
	 * 
* @see * CXTPPropExchangeEnumerator */ virtual CXTPPropExchangeEnumerator* GetEnumerator(LPCTSTR lpszSection); public: static void AFX_CDECL BinToString(BYTE* pData, DWORD nBytes, CString& str); static BOOL AFX_CDECL StringToBin(const CString& str, BYTE*& pData, DWORD& nBytes); protected: /** * @brief * This methods is called to copy internal data from root section. * @param pRootSection Parent section */ void InitSection(CXTPPropExchange* pRootSection); /** @cond */ public: static void AFX_CDECL PreformatString(CString& strValue, BOOL bLoading); virtual void ExchangeSchemaSafe(); protected: DWORD GetSizeOfVarType(VARTYPE vt); BOOL IsSamePropValue(VARTYPE vtProp, const void* pv1, const void* pv2); BOOL CopyPropValue(VARTYPE vtProp, void* pvDest, const void* pvSrc); BOOL ExchangePropStringHelper(CString& strValue, VARTYPE vtProp, void* pvProp, const void* pvDefault); BOOL ExchangePropDateHelper(CString& strValue, COleDateTime& dt); void PreformatString(CString& strValue); void PreformatString(BSTR bstrValue); public: static CRuntimeClass* AFX_CDECL FindRuntimeClass(LPCSTR szClassName); /** @endcond */ public: DWORD_PTR m_dwData; /**< User-defined 32-bit value. */ CObject* m_pOwner; /**< User-defined Owner value. */ static LCID m_lcidDateTime; /**< User regional language */ protected: BOOL m_bLoading; /**< TRUE if properties are being loaded to the class. */ UINT m_nSchema; /**< Schema of object. */ BOOL m_bChildSection; /**< TRUE if section is child */ BOOL m_bEmptySection; /**< TRUE if EmptySection method was called. */ BOOL m_bInitialized; /**< TRUE if section was initialized. */ BOOL m_bUseDefaultOnLoad; /**< TRUE if default values must be used in load process. */ BOOL m_bUseDefaultOnSave; /**< TRUE if default values must be used in save process. */ }; /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type BYTE. The property's value is * read from or written to the variable referenced by nValue, as appropriate. * If nDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param nDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Byte(CXTPPropExchange* pPX, LPCTSTR pszPropName, BYTE& nValue, BYTE nDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type short. The property's value is * read from or written to the variable referenced by sValue, as appropriate. * If sDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param sValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Short(CXTPPropExchange* pPX, LPCTSTR pszPropName, short& sValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type short. The property's value is * read from or written to the variable referenced by sValue, as appropriate. * If sDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param sValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param sDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Short(CXTPPropExchange* pPX, LPCTSTR pszPropName, short& sValue, short sDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type USHORT. The property's value is * read from or written to the variable referenced by usValue, as appropriate. * If usDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param usValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_UShort(CXTPPropExchange* pPX, LPCTSTR pszPropName, USHORT& usValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type USHORT. The property's value is * read from or written to the variable referenced by usValue, as appropriate. * If usDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param usValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param usDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_UShort(CXTPPropExchange* pPX, LPCTSTR pszPropName, USHORT& usValue, USHORT usDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type long. The property's value is * read from or written to the variable referenced by lValue, as appropriate. * If lDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param lValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Long(CXTPPropExchange* pPX, LPCTSTR pszPropName, long& lValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type long. The property's value is * read from or written to the variable referenced by lValue, as appropriate. * If lDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param lValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param lDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Long(CXTPPropExchange* pPX, LPCTSTR pszPropName, long& lValue, long lDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type long. The property's value is * read from or written to the variable referenced by lValue, as appropriate. * If lDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param lValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_X_Long(CXTPPropExchange* pPX, LPCTSTR pszPropName, long& lValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type long. The property's value is * read from or written to the variable referenced by lValue, as appropriate. * If lDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param lValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param lDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_X_Long(CXTPPropExchange* pPX, LPCTSTR pszPropName, long& lValue, long lDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type long. The property's value is * read from or written to the variable referenced by lValue, as appropriate. * If lDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param lValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_Y_Long(CXTPPropExchange* pPX, LPCTSTR pszPropName, long& lValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type long. The property's value is * read from or written to the variable referenced by lValue, as appropriate. * If lDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param lValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param lDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_Y_Long(CXTPPropExchange* pPX, LPCTSTR pszPropName, long& lValue, long lDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type DWORD. The property's value is * read from or written to the variable referenced by dwValue, as appropriate. * If dwDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param dwValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DWord(CXTPPropExchange* pPX, LPCTSTR pszPropName, DWORD& dwValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type DWORD. The property's value is * read from or written to the variable referenced by dwValue, as appropriate. * If dwDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param dwValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param dwDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DWord(CXTPPropExchange* pPX, LPCTSTR pszPropName, DWORD& dwValue, DWORD dwDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type ULONGLONG. The property's value is * read from or written to the variable referenced by ullValue, as appropriate. * If ullDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ullValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param ullDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_UI8(CXTPPropExchange* pPX, LPCTSTR pszPropName, ULONGLONG& ullValue, ULONGLONG ullDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type int. The property's value is * read from or written to the variable referenced by nValue, as appropriate. * If nDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Int(CXTPPropExchange* pPX, LPCTSTR pszPropName, int& nValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type DWORD. The property's value is * read from or written to the variable referenced by dwValue, as appropriate. * If dwDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * @param nDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Int(CXTPPropExchange* pPX, LPCTSTR pszPropName, int& nValue, int nDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type DWORD. The property's value is * read from or written to the variable referenced by dwValue, as appropriate. * If dwDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_X_Int(CXTPPropExchange* pPX, LPCTSTR pszPropName, int& nValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type DWORD. The property's value is * read from or written to the variable referenced by dwValue, as appropriate. * If dwDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * @param nDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_X_Int(CXTPPropExchange* pPX, LPCTSTR pszPropName, int& nValue, int nDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type DWORD. The property's value is * read from or written to the variable referenced by dwValue, as appropriate. * If dwDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_Y_Int(CXTPPropExchange* pPX, LPCTSTR pszPropName, int& nValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type DWORD. The property's value is * read from or written to the variable referenced by dwValue, as appropriate. * If dwDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * @param nDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_Y_Int(CXTPPropExchange* pPX, LPCTSTR pszPropName, int& nValue, int nDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type ULONG. The property's value is * read from or written to the variable referenced by ulValue, as appropriate. * If ulDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ulValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_ULong(CXTPPropExchange* pPX, LPCTSTR pszPropName, ULONG& ulValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type ULONG. The property's value is * read from or written to the variable referenced by ulValue, as appropriate. * If ulDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ulValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param ulDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_ULong(CXTPPropExchange* pPX, LPCTSTR pszPropName, ULONG& ulValue, ULONG ulDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type BOOL. The property's value is * read from or written to the variable referenced by bValue, as appropriate. * If bDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param bValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Bool(CXTPPropExchange* pPX, LPCTSTR pszPropName, BOOL& bValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type BOOL. The property's value is * read from or written to the variable referenced by bValue, as appropriate. * If bDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param bValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param bDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Bool(CXTPPropExchange* pPX, LPCTSTR pszPropName, BOOL& bValue, BOOL bDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a character string property. The property's value is * read from or written to the variable referenced by strValue, as appropriate. * If lpszDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param strValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_String(CXTPPropExchange* pPX, LPCTSTR pszPropName, CString& strValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a character string property. The property's value is * read from or written to the variable referenced by strValue, as appropriate. * If lpszDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param strValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param lpszDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_String(CXTPPropExchange* pPX, LPCTSTR pszPropName, CString& strValue, LPCTSTR lpszDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a character string property. The property's value is * read from or written to the variable referenced by strValue, as appropriate. * If lpszDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param bstrValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param bstrDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Bstr(CXTPPropExchange* pPX, LPCTSTR pszPropName, BSTR& bstrValue, BSTR bstrDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type float. The property's value is * read from or written to the variable referenced by floatValue, as appropriate. * If floatDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param floatValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Float(CXTPPropExchange* pPX, LPCTSTR pszPropName, float& floatValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type float. The property's value is * read from or written to the variable referenced by floatValue, as appropriate. * If floatDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param floatValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param floatDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Float(CXTPPropExchange* pPX, LPCTSTR pszPropName, float& floatValue, float floatDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type double. The property's value is * read from or written to the variable referenced by doubleValue, as appropriate. * If doubleDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param doubleValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Double(CXTPPropExchange* pPX, LPCTSTR pszPropName, double& doubleValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type double. The property's value is * read from or written to the variable referenced by doubleValue, as appropriate. * If doubleDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param doubleValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param doubleDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Double(CXTPPropExchange* pPX, LPCTSTR pszPropName, double& doubleValue, double doubleDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type SIZE. The property's value is * read from or written to the variable referenced by szValue, as appropriate. * If szDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param szValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param szDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Size(CXTPPropExchange* pPX, LPCTSTR pszPropName, SIZE& szValue, SIZE szDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type SIZE. The property's value is * read from or written to the variable referenced by szValue, as appropriate. * If szDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param szValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param szDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_Size(CXTPPropExchange* pPX, LPCTSTR pszPropName, SIZE& szValue, SIZE szDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type RECT. The property's value is * read from or written to the variable referenced by rcValue, as appropriate. * If rcDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param rcValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param rcDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Rect(CXTPPropExchange* pPX, LPCTSTR pszPropName, RECT& rcValue, RECT rcDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type RECT. The property's value is * read from or written to the variable referenced by rcValue, as appropriate. * If rcDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param rcValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param rcDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_Rect(CXTPPropExchange* pPX, LPCTSTR pszPropName, RECT& rcValue, RECT rcDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type POINT. The property's value is * read from or written to the variable referenced by ptValue, as appropriate. * If ptDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ptValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param ptDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Point(CXTPPropExchange* pPX, LPCTSTR pszPropName, POINT& ptValue, POINT ptDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type POINT. The property's value is * read from or written to the variable referenced by ptValue, as appropriate. * If ptDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ptValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param ptDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DPI_Point(CXTPPropExchange* pPX, LPCTSTR pszPropName, POINT& ptValue, POINT ptDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type POINT. The property's value is * read from or written to the variable referenced by ptValue, as appropriate. * If ptDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ptValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param ptDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Point(CXTPPropExchange* pPX, LPCTSTR pszPropName, CXTPPoint3T& ptValue, CXTPPoint3T ptDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type POINT. The property's value is * read from or written to the variable referenced by ptValue, as appropriate. * If ptDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ptValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param ptDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Point(CXTPPropExchange* pPX, LPCTSTR pszPropName, CXTPPoint3T& ptValue, CXTPPoint3T ptDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type POINT. The property's value is * read from or written to the variable referenced by ptValue, as appropriate. * If ptDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * The DPI version of the function stores the value as a DPI independent value. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param ptValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param ptDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Point(CXTPPropExchange* pPX, LPCTSTR pszPropName, CXTPPoint3T& ptValue, CXTPPoint3T ptDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type COleDateTime. The property's value is * read from or written to the variable referenced by dtValue, as appropriate. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param dtValue Reference to the variable where the property is stored * (typically a member variable of your class). * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_DateTime(CXTPPropExchange* pPX, LPCTSTR pszPropName, COleDateTime& dtValue); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type CRuntimeClass. The property's value is * read from or written to the variable referenced by pClass, as appropriate. * If pDefaultClass is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param pClass Reference to the variable where the property is stored * (typically a member variable of your class). * @param pDefaultClass Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_RuntimeClass(CXTPPropExchange* pPX, LPCTSTR pszPropName, CRuntimeClass*& pClass, CRuntimeClass* pDefaultClass); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize an object. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param pObject Object you need to serialize. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Serialize(CXTPPropExchange* pPX, LPCTSTR pszPropName, CObject* pObject); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize a BYTE array. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param pData Byte array. * @param nBytes Size of Byte array. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Blob(CXTPPropExchange* pPX, LPCTSTR pszPropName, BYTE*& pData, DWORD& nBytes); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize a property of type COleVariant. The property's value is * read from or written to the variable referenced by variant, as appropriate. * If variantDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param variant Reference to the variable where the property is stored * (typically a member variable of your class). * @param variantDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ _XTP_EXT_CLASS BOOL AFX_CDECL PX_Variant(CXTPPropExchange* pPX, LPCTSTR pszPropName, COleVariant& variant, COleVariant variantDefault); /** * @brief * Call this function within your class's DoPropExchange member function to * serialize or initialize an enum property. The property's value is * read from or written to the variable referenced by nValue, as appropriate. * If nDefault is specified, it will be used as the property's default value. * This value is used if, for any reason, the serialization process fails. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param nValue Reference to the variable where the property is stored * (typically a member variable of your class). * @param nDefault Default value for the property. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ template AFX_INLINE BOOL AFX_CDECL PX_Enum(CXTPPropExchange* pPX, LPCTSTR pszPropName, TEnum& nValue, TEnum nDefault) { _ASSERTE(sizeof(TEnum) == sizeof(int)); return PX_Int(pPX, pszPropName, (int&)nValue, (int)nDefault); } /** * @brief * Call this function within your class's DoPropExchange member function to * serialize any class that has the DoPropExchange method. * @param pPX Pointer to the CXTPPropExchange object (typically * passed as a parameter to DoPropExchange). * @param pszPropName The name of the property being exchanged. * @param pObject Reference to the object. * @param pObjectRuntime Default runtime class of object. * @return * Nonzero if the exchange was successful, 0 if unsuccessful. */ template AFX_INLINE BOOL AFX_CDECL PX_Object(CXTPPropExchange* pPX, LPCTSTR pszPropName, TObject*& pObject, CRuntimeClass* pObjectRuntime) { CXTPPropExchangeSection secObject(pPX->GetSection(pszPropName)); if (!secObject->ExchangeObjectInstance((CObject*&)pObject, pObjectRuntime)) return FALSE; pObject->DoPropExchange(&secObject); return TRUE; } template AFX_INLINE BOOL AFX_CDECL PX_Object(CXTPPropExchange* pPX, TObject*& pObject, CRuntimeClass* pObjectRuntime) { if (!pPX->ExchangeObjectInstance((CObject*&)pObject, pObjectRuntime)) return FALSE; pObject->DoPropExchange(pPX); return TRUE; } /** @cond */ AFX_INLINE BOOL CXTPPropExchange::OnBeforeExchange() { m_bInitialized = TRUE; return TRUE; } AFX_INLINE void CXTPPropExchange::UseDefaultOnLoad(BOOL bUseDefaultOnLoad) { m_bUseDefaultOnLoad = bUseDefaultOnLoad; } AFX_INLINE void CXTPPropExchange::UseDefaultOnSave(BOOL bUseDefaultOnSave) { m_bUseDefaultOnSave = bUseDefaultOnSave; } AFX_INLINE BOOL CXTPPropExchange::IsLoading() const { return m_bLoading; } AFX_INLINE BOOL CXTPPropExchange::IsStoring() const { return !m_bLoading; } AFX_INLINE UINT CXTPPropExchange::GetSchema() const { return m_nSchema; } void AFX_INLINE CXTPPropExchange::SetSchema(UINT nSchemaVersion) { m_nSchema = nSchemaVersion; } AFX_INLINE BOOL CXTPPropExchange::IsRootSection() const { return !m_bChildSection; } AFX_INLINE BOOL CXTPPropExchange::IsAllowDefaultValues() const { return TRUE; } AFX_INLINE BOOL CXTPPropExchange::IsAllowBlobValues() const { return FALSE; } /** @endcond */ # ifdef _XTP_ACTIVEX /** @cond */ extern CXTPPropExchange* AFX_CDECL PropExchangeFromControl(LPDISPATCH lpDispatch); /** @endcond */ # endif # include "Common/Base/Diagnostic/XTPEnableNoisyWarnings.h" /** @cond */ #endif // #if !defined(__XTPPROPEXCHANGE_H__) /** @endcond */