PluginPropertyItem.php 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  1. <?php
  2. /* vim: set expandtab sw=4 ts=4 sts=4: */
  3. /**
  4. * The top-level class of the "Plugin" subtree of the object-oriented
  5. * properties system (the other subtree is "Options").
  6. *
  7. * @package PhpMyAdmin
  8. */
  9. namespace PhpMyAdmin\Properties\Plugins;
  10. use PhpMyAdmin\Properties\Options\Groups\OptionsPropertyRootGroup;
  11. use PhpMyAdmin\Properties\PropertyItem;
  12. /**
  13. * Superclass for
  14. * - PhpMyAdmin\Properties\Plugins\ExportPluginProperties,
  15. * - PhpMyAdmin\Properties\Plugins\ImportPluginProperties and
  16. * - TransformationsPluginProperties
  17. *
  18. * @package PhpMyAdmin
  19. */
  20. abstract class PluginPropertyItem extends PropertyItem
  21. {
  22. /**
  23. * Text
  24. *
  25. * @var string
  26. */
  27. private $_text;
  28. /**
  29. * Extension
  30. *
  31. * @var string
  32. */
  33. private $_extension;
  34. /**
  35. * Options
  36. *
  37. * @var OptionsPropertyRootGroup
  38. */
  39. private $_options;
  40. /**
  41. * Options text
  42. *
  43. * @var string
  44. */
  45. private $_optionsText;
  46. /**
  47. * MIME Type
  48. *
  49. * @var string
  50. */
  51. private $_mimeType;
  52. /* ~~~~~~~~~~~~~~~~~~~~ Getters and Setters ~~~~~~~~~~~~~~~~~~~~ */
  53. /**
  54. * Gets the text
  55. *
  56. * @return string
  57. */
  58. public function getText()
  59. {
  60. return $this->_text;
  61. }
  62. /**
  63. * Sets the text
  64. *
  65. * @param string $text text
  66. *
  67. * @return void
  68. */
  69. public function setText($text)
  70. {
  71. $this->_text = $text;
  72. }
  73. /**
  74. * Gets the extension
  75. *
  76. * @return string
  77. */
  78. public function getExtension()
  79. {
  80. return $this->_extension;
  81. }
  82. /**
  83. * Sets the extension
  84. *
  85. * @param string $extension extension
  86. *
  87. * @return void
  88. */
  89. public function setExtension($extension)
  90. {
  91. $this->_extension = $extension;
  92. }
  93. /**
  94. * Gets the options
  95. *
  96. * @return OptionsPropertyRootGroup
  97. */
  98. public function getOptions()
  99. {
  100. return $this->_options;
  101. }
  102. /**
  103. * Sets the options
  104. *
  105. * @param OptionsPropertyRootGroup $options options
  106. *
  107. * @return void
  108. */
  109. public function setOptions($options)
  110. {
  111. $this->_options = $options;
  112. }
  113. /**
  114. * Gets the options text
  115. *
  116. * @return string
  117. */
  118. public function getOptionsText()
  119. {
  120. return $this->_optionsText;
  121. }
  122. /**
  123. * Sets the options text
  124. *
  125. * @param string $optionsText optionsText
  126. *
  127. * @return void
  128. */
  129. public function setOptionsText($optionsText)
  130. {
  131. $this->_optionsText = $optionsText;
  132. }
  133. /**
  134. * Gets the MIME type
  135. *
  136. * @return string
  137. */
  138. public function getMimeType()
  139. {
  140. return $this->_mimeType;
  141. }
  142. /**
  143. * Sets the MIME type
  144. *
  145. * @param string $mimeType MIME type
  146. *
  147. * @return void
  148. */
  149. public function setMimeType($mimeType)
  150. {
  151. $this->_mimeType = $mimeType;
  152. }
  153. /**
  154. * Returns the property type ( either "options", or "plugin" ).
  155. *
  156. * @return string
  157. */
  158. public function getPropertyType()
  159. {
  160. return "plugin";
  161. }
  162. }