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.

142 lines
3.4 KiB

  1. /*****************************************************************/
  2. /** Microsoft Windows **/
  3. //* Copyright (c) Microsoft Corporation. All rights reserved. **/
  4. /*****************************************************************/
  5. /*
  6. msshrui.h
  7. Prototypes and definitions for sharing APIs
  8. FILE HISTORY:
  9. gregj 06/03/93 Created
  10. brucefo 3/5/96 Fixed prototypes for NT
  11. */
  12. #ifndef _INC_MSSHRUI
  13. #define _INC_MSSHRUI
  14. #ifndef RC_INVOKED
  15. #pragma pack(1) /* Assume byte packing throughout */
  16. #endif /* !RC_INVOKED */
  17. #ifdef __cplusplus
  18. extern "C" { /* Assume C declarations for C++ */
  19. #endif /* __cplusplus */
  20. // Note: ANSI entrypoints are no longer supported!
  21. STDAPI_(BOOL) IsPathSharedW(
  22. IN LPCWSTR lpPath,
  23. IN BOOL fRefresh
  24. );
  25. typedef
  26. BOOL
  27. (WINAPI* PFNISPATHSHARED)(
  28. IN LPCWSTR lpPath,
  29. IN BOOL fRefresh
  30. );
  31. STDAPI_(BOOL) SharingDialogW(
  32. IN HWND hwndParent,
  33. IN LPCWSTR pszComputerName,
  34. IN LPCWSTR pszPath
  35. );
  36. typedef
  37. BOOL
  38. (WINAPI* PFNSHARINGDIALOG)(
  39. IN HWND hwndParent,
  40. IN LPCWSTR pszComputerName,
  41. IN LPCWSTR pszPath
  42. );
  43. STDAPI_(BOOL) GetNetResourceFromLocalPathW(
  44. IN LPCWSTR lpcszPath,
  45. IN OUT LPWSTR lpszNameBuf,
  46. IN DWORD cchNameBufLen,
  47. OUT PDWORD pdwNetType
  48. );
  49. typedef
  50. BOOL
  51. (WINAPI* PFNGETNETRESOURCEFROMLOCALPATH)(
  52. IN LPCWSTR lpcszPath,
  53. IN OUT LPWSTR lpszNameBuf,
  54. IN DWORD cchNameBufLen,
  55. OUT PDWORD pdwNetType
  56. );
  57. STDAPI_(BOOL) GetLocalPathFromNetResourceW(
  58. IN LPCWSTR lpcszName,
  59. IN DWORD dwNetType,
  60. IN OUT LPWSTR lpszLocalPathBuf,
  61. IN DWORD cchLocalPathBufLen,
  62. OUT PBOOL pbIsLocal
  63. );
  64. typedef
  65. BOOL
  66. (WINAPI* PFNGETLOCALPATHFROMNETRESOURCE)(
  67. IN LPCWSTR lpcszName,
  68. IN DWORD dwNetType,
  69. IN OUT LPWSTR lpszLocalPathBuf,
  70. IN DWORD cchLocalPathBufLen,
  71. OUT PBOOL pbIsLocal
  72. );
  73. #ifdef UNICODE
  74. #define IsPathShared IsPathSharedW
  75. #define SharingDialog SharingDialogW
  76. #define GetNetResourceFromLocalPath GetNetResourceFromLocalPathW
  77. #define GetLocalPathFromNetResource GetLocalPathFromNetResourceW
  78. #endif
  79. // Flags returned by IsFolderPrivateForUser via pdwPrivateType
  80. #define IFPFU_NOT_PRIVATE 0x0000
  81. #define IFPFU_PRIVATE 0x0001
  82. #define IFPFU_PRIVATE_INHERITED 0x0002
  83. #define IFPFU_NOT_NTFS 0x0004
  84. STDAPI_(BOOL) IsFolderPrivateForUser(
  85. IN PCWSTR pszFolderPath,
  86. IN PCWSTR pszUserSID,
  87. OUT PDWORD pdwPrivateType,
  88. OUT PWSTR* ppszInheritanceSource
  89. );
  90. typedef
  91. BOOL
  92. (WINAPI* PFNISFOLDERPRIVATEFORUSER)(
  93. IN PCWSTR pszFolderPath,
  94. IN PCWSTR pszUserSID,
  95. OUT PDWORD pdwPrivateType,
  96. OUT PWSTR* ppszInheritanceSource
  97. );
  98. STDAPI_(BOOL) SetFolderPermissionsForSharing(
  99. IN PCWSTR pszFolderPath,
  100. IN PCWSTR pszUserSID,
  101. IN DWORD dwLevel,
  102. IN HWND hwndParent
  103. );
  104. typedef
  105. BOOL
  106. (WINAPI* PFNSETFOLDERPERMISSIONSFORSHARING)(
  107. IN PCWSTR pszFolderPath,
  108. IN PCWSTR pszUserSID,
  109. IN DWORD dwLevel,
  110. IN HWND hwndParent
  111. );
  112. #ifndef RC_INVOKED
  113. #pragma pack()
  114. #endif
  115. #ifdef __cplusplus
  116. }
  117. #endif /* __cplusplus */
  118. #endif /* !_INC_MSSHRUI */