summaryrefslogtreecommitdiff
path: root/framework/Web/UI/WebControls/TLabel.php
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Web/UI/WebControls/TLabel.php')
-rw-r--r--framework/Web/UI/WebControls/TLabel.php28
1 files changed, 27 insertions, 1 deletions
diff --git a/framework/Web/UI/WebControls/TLabel.php b/framework/Web/UI/WebControls/TLabel.php
index 5d213529..7821580a 100644
--- a/framework/Web/UI/WebControls/TLabel.php
+++ b/framework/Web/UI/WebControls/TLabel.php
@@ -30,7 +30,7 @@
* @package System.Web.UI.WebControls
* @since 3.0
*/
-class TLabel extends TWebControl
+class TLabel extends TWebControl implements IDataRenderer
{
private $_forControl='';
@@ -108,6 +108,32 @@ class TLabel extends TWebControl
}
/**
+ * Returns the text value of the label.
+ * This method is required by {@link IDataRenderer}.
+ * It is the same as {@link getText()}.
+ * @return string the text value of the label
+ * @see getText
+ * @since 3.1.0
+ */
+ public function getData()
+ {
+ return $this->getText();
+ }
+
+ /**
+ * Sets the text value of the label.
+ * This method is required by {@link IDataRenderer}.
+ * It is the same as {@link setText()}.
+ * @param string the text value of the label
+ * @see setText
+ * @since 3.1.0
+ */
+ public function setData($value)
+ {
+ $this->setText($value);
+ }
+
+ /**
* @return string the associated control ID
*/
public function getForControl()