PluginPropertyItem.class.php 3.0 KB

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