Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
1.7 KiB

  1. /*++
  2. Copyright (C) 1996-1999 Microsoft Corporation
  3. Module Name:
  4. ipropbag.h
  5. Abstract:
  6. <abstract>
  7. --*/
  8. #ifndef _IPROPBAG_H_
  9. #define _IPROPBAG_H_
  10. // Property Bag Class
  11. class CImpIPropertyBag : public IPropertyBag {
  12. public:
  13. CImpIPropertyBag( LPUNKNOWN = NULL );
  14. virtual ~CImpIPropertyBag(void);
  15. //IUnknown members
  16. STDMETHODIMP QueryInterface(REFIID, LPVOID *);
  17. STDMETHODIMP_(ULONG) AddRef(void);
  18. STDMETHODIMP_(ULONG) Release(void);
  19. //IConnectionPoint members
  20. STDMETHODIMP Read(LPCOLESTR, VARIANT*, IErrorLog* );
  21. STDMETHODIMP Write(LPCOLESTR, VARIANT* );
  22. //Members not exposed by IPropertyBag
  23. LPWSTR GetData ( void );
  24. HRESULT LoadData ( LPWSTR pszData );
  25. private:
  26. typedef struct _param_data {
  27. _param_data* pNextParam;
  28. WCHAR pszPropertyName[MAX_PATH];
  29. VARIANT vValue;
  30. } PARAM_DATA, *PPARAM_DATA;
  31. enum eConstants {
  32. eDefaultBufferLength = 0x010000 // 64K
  33. };
  34. PPARAM_DATA FindProperty ( LPCWSTR pszPropName );
  35. void DataListAddHead ( PPARAM_DATA );
  36. PPARAM_DATA DataListRemoveHead ( void );
  37. ULONG m_cRef; //Object reference count
  38. LPUNKNOWN m_pUnkOuter; //Controlling unknown
  39. // PCPolyline m_pObj; //Containing object - assume NULL for this object
  40. LPWSTR m_pszData;
  41. DWORD m_dwCurrentDataLength;
  42. PPARAM_DATA m_plistData;
  43. };
  44. typedef CImpIPropertyBag *PCImpIPropertyBag;
  45. #endif // _IPROPBAG_H_