PageRenderTime 43ms CodeModel.GetById 17ms RepoModel.GetById 1ms app.codeStats 0ms

/trunk/Powershell/PHPConfigurationItem.cs

#
C# | 89 lines | 69 code | 12 blank | 8 comment | 0 complexity | 75dbf404caba7682ca71a3f8f6337d89 MD5 | raw file
Possible License(s): CC-BY-SA-3.0
  1. //-----------------------------------------------------------------------
  2. // <copyright>
  3. // Copyright (C) Ruslan Yakushev for the PHP Manager for IIS project.
  4. //
  5. // This file is subject to the terms and conditions of the Microsoft Public License (MS-PL).
  6. // See http://www.microsoft.com/opensource/licenses.mspx#Ms-PL for more details.
  7. // </copyright>
  8. //-----------------------------------------------------------------------
  9. using Web.Management.PHP.Config;
  10. namespace Web.Management.PHP.Powershell
  11. {
  12. public enum HandlerRegistrationType { Local, Inherited };
  13. public sealed class PHPConfigurationItem
  14. {
  15. private readonly PHPConfigInfo _configInfo;
  16. public PHPConfigurationItem(PHPConfigInfo configInfo)
  17. {
  18. _configInfo = configInfo;
  19. }
  20. public string HandlerName
  21. {
  22. get
  23. {
  24. return _configInfo.HandlerName;
  25. }
  26. }
  27. public string Version
  28. {
  29. get
  30. {
  31. return _configInfo.Version;
  32. }
  33. }
  34. public string ScriptProcessor
  35. {
  36. get
  37. {
  38. return _configInfo.Executable;
  39. }
  40. }
  41. public HandlerRegistrationType HandlerType
  42. {
  43. get
  44. {
  45. return _configInfo.HandlerIsLocal ? HandlerRegistrationType.Local : HandlerRegistrationType.Inherited;
  46. }
  47. }
  48. public string ErrorLog
  49. {
  50. get
  51. {
  52. return _configInfo.ErrorLog;
  53. }
  54. }
  55. public string PHPIniFilePath
  56. {
  57. get
  58. {
  59. return _configInfo.PHPIniFilePath;
  60. }
  61. }
  62. public int InstalledExtensionsCount
  63. {
  64. get
  65. {
  66. return _configInfo.InstalledExtCount;
  67. }
  68. }
  69. public int EnabledExtensionsCount
  70. {
  71. get
  72. {
  73. return _configInfo.EnabledExtCount;
  74. }
  75. }
  76. }
  77. }