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.

105 lines
2.0 KiB

  1. /*++
  2. Copyright (c) 1998-2000 Microsoft Corporation
  3. Module Name:
  4. appladmin.h
  5. Abstract:
  6. This file contains definition of:
  7. CAppPoolMethod, CWebAppMethod
  8. Author:
  9. ???
  10. Revision History:
  11. Mohit Srivastava 21-Jan-01
  12. --*/
  13. #ifndef _appladmin_h_
  14. #define _appladmin_h_
  15. #include <atlbase.h>
  16. class CAppPoolMethod
  17. {
  18. public:
  19. CAppPoolMethod();
  20. ~CAppPoolMethod();
  21. void GetCurrentMode(
  22. VARIANT* io_pvtServerMode);
  23. void Start(
  24. LPCWSTR i_wszMbPath);
  25. void Stop(
  26. LPCWSTR i_wszMbPath);
  27. void RecycleAppPool(
  28. LPCWSTR i_wszMbPath);
  29. void EnumAppsInPool(
  30. LPCWSTR i_wszMbPath,
  31. VARIANT* io_pvtApps);
  32. void DeleteAppPool(
  33. LPCWSTR i_wszMbPath);
  34. private:
  35. void GetPtrToAppPool(
  36. LPCWSTR i_wszMbPath,
  37. LPCWSTR* o_pwszAppPool);
  38. HRESULT IISGetAppPoolState(
  39. METADATA_HANDLE hObjHandle,
  40. LPDWORD pdwState);
  41. HRESULT IISSetDword(
  42. METADATA_HANDLE hKey,
  43. DWORD dwPropId,
  44. DWORD dwValue);
  45. HRESULT IISGetAppPoolWin32Error(
  46. METADATA_HANDLE hObjHandle,
  47. HRESULT* phrError);
  48. HRESULT ExecMethod(
  49. DWORD dwControl);
  50. CComPtr<IIISApplicationAdmin> m_spAppAdmin;
  51. CMetabase metabase;
  52. CComPtr<IMSAdminBase> m_pIABase;
  53. LPCWSTR m_wszPath; // full metabase path of loc where we will execute method
  54. };
  55. class CWebAppMethod
  56. {
  57. private:
  58. IIISApplicationAdmin* m_pAppAdmin;
  59. IWamAdmin2* m_pWamAdmin2;
  60. public:
  61. CWebAppMethod();
  62. ~CWebAppMethod();
  63. HRESULT AppCreate(LPCWSTR, bool);
  64. HRESULT AppCreate2(LPCWSTR, long);
  65. HRESULT AppCreate3(LPCWSTR, long, LPCWSTR, bool);
  66. HRESULT AppDelete(LPCWSTR, bool);
  67. HRESULT AppUnLoad(LPCWSTR, bool);
  68. HRESULT AppDisable(LPCWSTR, bool);
  69. HRESULT AppEnable(LPCWSTR, bool);
  70. HRESULT AppGetStatus(LPCWSTR, DWORD*);
  71. HRESULT AspAppRestart(LPCWSTR);
  72. };
  73. #endif // _appladmin_h