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.

169 lines
4.6 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (c) Microsoft Corporation. All rights reserved.
  5. //
  6. // File: IDirectory.idl
  7. //
  8. // Contents: IDirectory interface definition
  9. //
  10. // History: 14-Jun-1995 HenryLee initial version
  11. //
  12. //--------------------------------------------------------------------------
  13. import "unknwn.idl";
  14. import "transact.idl";
  15. interface IEnumSTATDIR;
  16. typedef enum tagSTGFMT
  17. {
  18. STGFMT_DOCUMENT = 0,
  19. STGFMT_DIRECTORY = 1,
  20. STGFMT_CATALOG = 2,
  21. STGFMT_FILE = 3,
  22. STGFMT_ANY = 4,
  23. STGFMT_DOCFILE = 5,
  24. STGFMT_STORAGE = 6,
  25. STGFMT_JUNCTION = 7
  26. } STGFMT;
  27. cpp_quote("#define STGFMT_FLATFILE STGFMT_FILE")
  28. typedef struct tagSTGTEMPLATE
  29. {
  30. IUnknown * pUnkTemplate;
  31. DWORD ciidTemplate;
  32. IID * riidTemplate;
  33. } STGTEMPLATE;
  34. typedef struct tagOBJECT_SECURITY_INIT
  35. {
  36. TRUSTEE_W * pTrusteeOwner;
  37. TRUSTEE_W * pTrusteeGroup;
  38. DWORD cAccessRightsLength;
  39. EXPLICIT_ACCESS_W *pAccessRightsList;
  40. DWORD cAuditEntriesLength;
  41. EXPLICIT_ACCESS_W *pAuditEntriesList;
  42. } OBJECT_SECURITY_INIT;
  43. typedef struct tagSTGCREATE
  44. {
  45. DWORD grfAttrs;
  46. STGTEMPLATE *pTemplate;
  47. OBJECT_SECURITY_INIT *pSecurity;
  48. } STGCREATE;
  49. typedef struct tagSTGOPEN
  50. {
  51. STGFMT stgfmt;
  52. DWORD grfMode;
  53. DWORD grfFlags;
  54. ITransaction * pTransaction;
  55. } STGOPEN;
  56. typedef struct tagSTATDIR
  57. {
  58. WCHAR * pwcsName;
  59. STGFMT stgfmt;
  60. DWORD grfAttrs;
  61. ULARGE_INTEGER cbSize;
  62. FILETIME mtime;
  63. FILETIME atime;
  64. FILETIME ctime;
  65. DWORD grfMode;
  66. CLSID clsid;
  67. DWORD grfStateBits;
  68. } STATDIR;
  69. [
  70. object,
  71. uuid(5c036ea0-b556-11ce-b33a-00aa00680937),
  72. pointer_default(unique)
  73. ]
  74. interface IDirectory : IUnknown
  75. {
  76. [local]
  77. HRESULT __stdcall CreateElement ([in] const WCHAR * pwcsName,
  78. [in] STGCREATE * pStgCreate,
  79. [in] STGOPEN * pStgOpen,
  80. [in] REFIID riid,
  81. [out] void ** ppObjectOpen);
  82. [call_as(CreateElement)]
  83. HRESULT __stdcall RemoteCreateElement ([in] const WCHAR * pwcsName,
  84. [in] STGCREATE * pStgCreate,
  85. [in] STGOPEN * pStgOpen,
  86. [in] REFIID riid,
  87. [out, iid_is(riid)] IUnknown ** ppObjectOpen);
  88. [local]
  89. HRESULT __stdcall OpenElement ([in] const WCHAR *pwcsName,
  90. [in] STGOPEN * pStgOpen,
  91. [in] REFIID riid,
  92. [out] STGFMT * pStgfmt,
  93. [out] void ** ppObjectOpen);
  94. [call_as(OpenElement)]
  95. HRESULT __stdcall RemoteOpenElement ([in] const WCHAR *pwcsName,
  96. [in] STGOPEN * pStgOpen,
  97. [in] REFIID riid,
  98. [out] STGFMT * pStgfmt,
  99. [out, iid_is(riid)] IUnknown ** ppObjectOpen);
  100. HRESULT MoveElement ([in] const WCHAR *pwcsName,
  101. [in, unique] IDirectory * pdirDest,
  102. [in, unique] const WCHAR * pwcsNewName,
  103. [in] DWORD grfFlags);
  104. HRESULT CommitDirectory ([in] DWORD grfCommitFlags);
  105. HRESULT RevertDirectory ();
  106. HRESULT DeleteElement ([in] const WCHAR *pwcsName);
  107. HRESULT SetTimes ([in, unique] const WCHAR *pwcsName,
  108. [in, unique] const FILETIME * pctime,
  109. [in, unique] const FILETIME * patime,
  110. [in, unique] const FILETIME * pmtime);
  111. HRESULT SetDirectoryClass ([in] REFCLSID clsid); // redudant ?
  112. HRESULT SetAttributes ([in, unique] const WCHAR * pwcsName,
  113. [in] DWORD grfAttrs);
  114. HRESULT StatElement ([in, unique] const WCHAR *pwcsName,
  115. [out] STATDIR *pstatdir,
  116. [in] DWORD grfStatFlag);
  117. HRESULT EnumDirectoryElements ([out] IEnumSTATDIR ** ppenum);
  118. }
  119. [
  120. object,
  121. uuid(74c76b90-b556-11ce-b33a-00aa00680937),
  122. pointer_default(unique)
  123. ]
  124. interface IEnumSTATDIR : IUnknown
  125. {
  126. [local]
  127. HRESULT __stdcall Next(
  128. [in] ULONG celt,
  129. [in] STATDIR * rgelt,
  130. [out] ULONG * pceltFetched );
  131. [call_as(Next)]
  132. HRESULT __stdcall RemoteNext(
  133. [in] ULONG celt,
  134. [out, size_is(celt), length_is(*pceltFetched)] STATDIR * rgelt,
  135. [out] ULONG * pceltFetched );
  136. HRESULT Skip([in] ULONG celt);
  137. HRESULT Reset();
  138. HRESULT Clone([out] IEnumSTATDIR ** ppenum);
  139. }