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.

110 lines
2.7 KiB

  1. //+--------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992 - 1992.
  5. //
  6. // File: revert.hxx
  7. //
  8. // Contents: PRevertable definition
  9. //
  10. // Classes: PRevertable
  11. //
  12. // History: 28-Apr-92 DrewB Created
  13. // 18-May-93 AlexT Added CMallocBased
  14. // 20-Jan-98 HenryLee remove virtual functions
  15. //
  16. // Notes: This class forms the root of all objects in the
  17. // transaction tree that understand reversion.
  18. // It allows lists of them to be formed.
  19. //
  20. //---------------------------------------------------------------
  21. #ifndef __REVERT_HXX__
  22. #define __REVERT_HXX__
  23. #include <dfmsp.hxx>
  24. class CChildInstanceList;
  25. class PRevertable;
  26. // signatures of all objects derived from PRevertable
  27. #define CPUBDOCFILE_SIG LONGSIG('P', 'B', 'D', 'F')
  28. #define CPUBDOCFILE_SIGDEL LONGSIG('P', 'b', 'D', 'f')
  29. #define CPUBSTREAM_SIG LONGSIG('P', 'B', 'S', 'T')
  30. #define CPUBSTREAM_SIGDEL LONGSIG('P', 'b', 'S', 't')
  31. #define CROOTPUBDOCFILE_SIG LONGSIG('R', 'P', 'D', 'F')
  32. #define CROOTPUBDOCFILE_SIGDEL LONGSIG('R', 'p', 'D', 'f')
  33. class PRevertable : public CMallocBased
  34. {
  35. public:
  36. void RevertFromAbove(void);
  37. #ifdef NEWPROPS
  38. SCODE FlushBufferedData(int recursionlevel);
  39. #endif
  40. void EmptyCache ();
  41. inline DFLUID GetLuid(void) const;
  42. inline DFLAGS GetDFlags(void) const;
  43. inline PRevertable *GetNext(void) const;
  44. friend class CChildInstanceList;
  45. protected:
  46. ULONG _sig;
  47. DFLUID _luid;
  48. DFLAGS _df;
  49. CDfName _dfn;
  50. private:
  51. CBasedRevertablePtr _prvNext;
  52. };
  53. //+--------------------------------------------------------------
  54. //
  55. // Member: PRevertable::GetLuid, public
  56. //
  57. // Synopsis: Returns the LUID
  58. //
  59. // History: 11-Aug-92 DrewB Created
  60. //
  61. //---------------------------------------------------------------
  62. inline DFLUID PRevertable::GetLuid(void) const
  63. {
  64. return _luid;
  65. }
  66. //+--------------------------------------------------------------
  67. //
  68. // Member: PRevertable::GetDFlags, public
  69. //
  70. // Synopsis: Returns the flags
  71. //
  72. // History: 11-Aug-92 DrewB Created
  73. //
  74. //---------------------------------------------------------------
  75. inline DFLAGS PRevertable::GetDFlags(void) const
  76. {
  77. return _df;
  78. }
  79. //+--------------------------------------------------------------
  80. //
  81. // Member: PRevertable::GetNext, public
  82. //
  83. // Synopsis: Returns the next revertable
  84. //
  85. // History: 11-Aug-92 DrewB Created
  86. //
  87. //---------------------------------------------------------------
  88. inline PRevertable *PRevertable::GetNext(void) const
  89. {
  90. return BP_TO_P(PRevertable *, _prvNext);
  91. }
  92. #endif // #ifndef __REVERT_HXX__