From 903ae8a581fac1e6917fc3e31d2ad8fb91df80c3 Mon Sep 17 00:00:00 2001 From: ctrlaltca <> Date: Thu, 12 Jul 2012 11:21:01 +0000 Subject: standardize the use of unix eol; use svn properties to enforce native eol --- framework/Web/UI/WebControls/TTextProcessor.php | 170 ++++++++++++------------ 1 file changed, 85 insertions(+), 85 deletions(-) (limited to 'framework/Web/UI/WebControls/TTextProcessor.php') diff --git a/framework/Web/UI/WebControls/TTextProcessor.php b/framework/Web/UI/WebControls/TTextProcessor.php index 6d95a482..60d047fe 100644 --- a/framework/Web/UI/WebControls/TTextProcessor.php +++ b/framework/Web/UI/WebControls/TTextProcessor.php @@ -1,86 +1,86 @@ - - * @link http://www.pradosoft.com/ + + * @link http://www.pradosoft.com/ * @copyright Copyright © 2005-2012 PradoSoft - * @license http://www.pradosoft.com/license/ - * @version $Id$ - * @package System.Web.UI.WebControls - */ - -/** - * TTextProcessor class. - * - * TTextProcessor is the base class for classes that process or transform - * text content into different forms. The text content to be processed - * is specified by {@link setText Text} property. If it is not set, the body - * content enclosed within the processor control will be processed and rendered. - * The body content includes static text strings and the rendering result - * of child controls. - * - * Note, all child classes must implement {@link processText} method. - * - * @author Qiang Xue - * @version $Id$ - * @package System.Web.UI - * @since 3.0.1 - */ -abstract class TTextProcessor extends TWebControl -{ - /** - * Processes a text string. - * This method must be implemented by child classes. - * @param string text string to be processed - * @return string the processed text result - */ - abstract public function processText($text); - - /** - * HTML-decodes static text. - * This method overrides parent implementation. - * @param mixed object to be added as body content - */ - public function addParsedObject($object) - { - if(is_string($object)) - $object=html_entity_decode($object,ENT_QUOTES,'UTF-8'); - parent::addParsedObject($object); - } - - /** - * @return string text to be processed - */ - public function getText() - { - return $this->getViewState('Text',''); - } - - /** - * @param string text to be processed - */ - public function setText($value) - { - $this->setViewState('Text',$value); - } - - /** - * Renders body content. - * This method overrides the parent implementation by replacing - * the body content with the processed text content. - * @param THtmlWriter writer - */ - public function renderContents($writer) - { - if(($text=$this->getText())==='' && $this->getHasControls()) - { - $htmlWriter = Prado::createComponent($this->GetResponse()->getHtmlWriterType(), new TTextWriter()); - parent::renderContents($htmlWriter); - $text=$htmlWriter->flush(); - } - if($text!=='') - $writer->write($this->processText($text)); - } - -} + * @license http://www.pradosoft.com/license/ + * @version $Id$ + * @package System.Web.UI.WebControls + */ + +/** + * TTextProcessor class. + * + * TTextProcessor is the base class for classes that process or transform + * text content into different forms. The text content to be processed + * is specified by {@link setText Text} property. If it is not set, the body + * content enclosed within the processor control will be processed and rendered. + * The body content includes static text strings and the rendering result + * of child controls. + * + * Note, all child classes must implement {@link processText} method. + * + * @author Qiang Xue + * @version $Id$ + * @package System.Web.UI + * @since 3.0.1 + */ +abstract class TTextProcessor extends TWebControl +{ + /** + * Processes a text string. + * This method must be implemented by child classes. + * @param string text string to be processed + * @return string the processed text result + */ + abstract public function processText($text); + + /** + * HTML-decodes static text. + * This method overrides parent implementation. + * @param mixed object to be added as body content + */ + public function addParsedObject($object) + { + if(is_string($object)) + $object=html_entity_decode($object,ENT_QUOTES,'UTF-8'); + parent::addParsedObject($object); + } + + /** + * @return string text to be processed + */ + public function getText() + { + return $this->getViewState('Text',''); + } + + /** + * @param string text to be processed + */ + public function setText($value) + { + $this->setViewState('Text',$value); + } + + /** + * Renders body content. + * This method overrides the parent implementation by replacing + * the body content with the processed text content. + * @param THtmlWriter writer + */ + public function renderContents($writer) + { + if(($text=$this->getText())==='' && $this->getHasControls()) + { + $htmlWriter = Prado::createComponent($this->GetResponse()->getHtmlWriterType(), new TTextWriter()); + parent::renderContents($htmlWriter); + $text=$htmlWriter->flush(); + } + if($text!=='') + $writer->write($this->processText($text)); + } + +} -- cgit v1.2.3