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.

153 lines
3.9 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992 - 1998.
  5. //
  6. // File: classf.hxx
  7. //
  8. // Contents: Class factory description
  9. //
  10. // History: 1-7-97 markz Created
  11. //
  12. //----------------------------------------------------------------------------
  13. #pragma once
  14. //
  15. // Standard Ole exports
  16. //
  17. extern "C" SCODE STDMETHODCALLTYPE FsciDllGetClassObject( REFCLSID cid,
  18. REFIID iid,
  19. void ** ppvObj );
  20. extern "C" const GUID guidStorageFilterObject;
  21. extern "C" const GUID guidStorageDocStoreLocatorObject;
  22. //+---------------------------------------------------------------------------
  23. //
  24. // Class: CStorageFilterObjectCF
  25. //
  26. // Purpose: Class factory to generate file system filter objects
  27. //
  28. // History: 1-7-97 markz Created
  29. //
  30. // Notes: This class is NOT multi-thread safe. The user must make sure
  31. // that only one thread is using it at a time.
  32. //
  33. //----------------------------------------------------------------------------
  34. class CStorageFilterObjectCF : public IClassFactory
  35. {
  36. public:
  37. //
  38. // Constructor and Destructor
  39. //
  40. CStorageFilterObjectCF( void );
  41. //
  42. // IUnknown methods.
  43. //
  44. STDMETHOD( QueryInterface ) ( THIS_ REFIID riid,LPVOID *ppiuk );
  45. STDMETHOD_( ULONG, AddRef ) ( THIS );
  46. STDMETHOD_( ULONG, Release ) ( THIS );
  47. //
  48. // IClassFactory methods.
  49. //
  50. STDMETHOD( CreateInstance ) ( THIS_
  51. IUnknown * pUnkOuter,
  52. REFIID riid,
  53. void * * ppvObject );
  54. STDMETHOD( LockServer ) ( THIS_ BOOL fLock );
  55. protected:
  56. //
  57. // Hidden destructor so that only we can delete the instance
  58. // based on IUnknown control
  59. //
  60. virtual ~CStorageFilterObjectCF();
  61. private:
  62. friend SCODE STDMETHODCALLTYPE FsciDllGetClassObject( REFCLSID cid,
  63. REFIID iid,
  64. void** ppvObj );
  65. //
  66. // IUnknown reference count.
  67. //
  68. LONG _RefCount;
  69. };
  70. //+---------------------------------------------------------------------------
  71. //
  72. // Class: CStorageDocStoreLocatorObjectCF
  73. //
  74. // Purpose: Class Factory to generate File System DocStore Locator object
  75. //
  76. // History: 1-16-97 srikants Created
  77. //
  78. //----------------------------------------------------------------------------
  79. class CStorageDocStoreLocatorObjectCF : public IClassFactory
  80. {
  81. public:
  82. //
  83. // IUnknown methods.
  84. //
  85. STDMETHOD( QueryInterface ) ( THIS_ REFIID riid,LPVOID *ppiuk );
  86. STDMETHOD_( ULONG, AddRef ) ( THIS );
  87. STDMETHOD_( ULONG, Release ) ( THIS );
  88. //
  89. // IClassFactory methods.
  90. //
  91. STDMETHOD( CreateInstance ) ( THIS_
  92. IUnknown * pUnkOuter,
  93. REFIID riid,
  94. void * * ppvObject );
  95. STDMETHOD( LockServer ) ( THIS_ BOOL fLock );
  96. protected:
  97. //
  98. // Constructor and Destructor
  99. //
  100. CStorageDocStoreLocatorObjectCF( void );
  101. //
  102. // Hidden destructor so that only we can delete the instance
  103. // based on IUnknown control
  104. //
  105. virtual ~CStorageDocStoreLocatorObjectCF();
  106. private:
  107. friend SCODE STDMETHODCALLTYPE FsciDllGetClassObject( REFCLSID cid,
  108. REFIID iid,
  109. void** ppvObj );
  110. //
  111. // IUnknown reference count.
  112. //
  113. LONG _RefCount;
  114. };