PageRenderTime 37ms CodeModel.GetById 12ms RepoModel.GetById 0ms app.codeStats 0ms

/tags/beta-1.0.2/Client/Config/PHPConfigInfo.cs

#
C# | 132 lines | 107 code | 17 blank | 8 comment | 0 complexity | 7fc9c6661372a60dc93f8bdccc93b127 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 System;
  10. namespace Web.Management.PHP.Config
  11. {
  12. internal sealed class PHPConfigInfo : IRemoteObject
  13. {
  14. private object[] _data;
  15. private const int IndexHandlerName = 0;
  16. private const int IndexScriptProcessor = 1;
  17. private const int IndexVersion = 2;
  18. private const int IndexPHPIniFilePath = 3;
  19. private const int IndexErrorLog = 4;
  20. private const int IndexEnabledExtCount = 5;
  21. private const int IndexInstalledExtCount = 6;
  22. private const int Size = 7;
  23. public PHPConfigInfo()
  24. {
  25. _data = new object[Size];
  26. }
  27. public int EnabledExtCount
  28. {
  29. get
  30. {
  31. return (int)_data[IndexEnabledExtCount];
  32. }
  33. set
  34. {
  35. _data[IndexEnabledExtCount] = value;
  36. }
  37. }
  38. public string ErrorLog
  39. {
  40. get
  41. {
  42. return (string)_data[IndexErrorLog];
  43. }
  44. set
  45. {
  46. _data[IndexErrorLog] = value;
  47. }
  48. }
  49. public string HandlerName
  50. {
  51. get
  52. {
  53. return (string)_data[IndexHandlerName];
  54. }
  55. set
  56. {
  57. _data[IndexHandlerName] = value;
  58. }
  59. }
  60. public int InstalledExtCount
  61. {
  62. get
  63. {
  64. return (int)_data[IndexInstalledExtCount];
  65. }
  66. set
  67. {
  68. _data[IndexInstalledExtCount] = value;
  69. }
  70. }
  71. public string PHPIniFilePath
  72. {
  73. get
  74. {
  75. return (string)_data[IndexPHPIniFilePath];
  76. }
  77. set
  78. {
  79. _data[IndexPHPIniFilePath] = value;
  80. }
  81. }
  82. public string ScriptProcessor
  83. {
  84. get
  85. {
  86. return (string)_data[IndexScriptProcessor];
  87. }
  88. set
  89. {
  90. _data[IndexScriptProcessor] = value;
  91. }
  92. }
  93. public string Version
  94. {
  95. get
  96. {
  97. return (string)_data[IndexVersion];
  98. }
  99. set
  100. {
  101. _data[IndexVersion] = value;
  102. }
  103. }
  104. #region IRemoteObject Members
  105. public object GetData()
  106. {
  107. return _data;
  108. }
  109. public void SetData(object o)
  110. {
  111. _data = (object[])o;
  112. }
  113. #endregion
  114. }
  115. }