From 88a3ef07397fbf679e0b70f9c73c4d4b806b0e41 Mon Sep 17 00:00:00 2001 From: "godzilla80@gmx.net" <> Date: Sat, 26 Feb 2011 14:18:50 +0000 Subject: CHG: Remove TReflectionClass and all references since equals ReflectionClass --- HISTORY | 1 + framework/PradoBase.php | 14 +------------- framework/TComponent.php | 10 +++++----- framework/Web/UI/TClientScriptManager.php | 8 ++++---- framework/Web/UI/TTemplateManager.php | 6 +++--- 5 files changed, 14 insertions(+), 25 deletions(-) diff --git a/HISTORY b/HISTORY index c010556e..c2517be2 100644 --- a/HISTORY +++ b/HISTORY @@ -19,6 +19,7 @@ CHG/ENH: Change behavior of THttpRequest::getBaseUrl() & THttpRequest::getAbsolu EHN: Add property SecureConnection to TUrlMappingPattern and related enum TUrlMappingPatternSecureConnection to make it possible to to define wether to use http or https on pattern level (Yves) EHN: Add second parameter to THttpResponse::appendHeader whether the header should replace a previous similar header, or add a second header of the same type (Yves) ENH: Add THttpSession::regenerate() to update the current session id with a newly generated one (Yves) +CHG: Remove TReflectionClass and all references since equals ReflectionClass (Yves) Version 3.1.7 February 22, 2010 ENH: Issue#24 - Specify needed fields on demand (Yves) diff --git a/framework/PradoBase.php b/framework/PradoBase.php index a164c596..08801807 100644 --- a/framework/PradoBase.php +++ b/framework/PradoBase.php @@ -420,7 +420,7 @@ class PradoBase if(isset($t['file'])) echo basename($t['file']) . ':' . $t['line']; else - echo ''; + echo ''; echo ' -- '; if(isset($t['class'])) echo $t['class'] . $t['type']; @@ -625,18 +625,6 @@ class PradoBase } } -/** - * TReflectionClass class. - * This class was originally written to cope with the incompatibility between different PHP versions. - * It is equivalent to ReflectionClass for PHP version >= 5.1.0 - * @author Qiang Xue - * @version $Id$ - * @package System - * @since 3.0 - */ -class TReflectionClass extends ReflectionClass -{ -} /** * Includes the classes essential for PradoBase class diff --git a/framework/TComponent.php b/framework/TComponent.php index 9b5331ef..9f51a4ef 100644 --- a/framework/TComponent.php +++ b/framework/TComponent.php @@ -90,8 +90,8 @@ class TComponent */ public function __construct() { } - - + + /** * Returns a property value or an event handler list by property or event name. * Do not call this method. This is a PHP magic method that we override @@ -365,7 +365,7 @@ class TComponent $method=substr($handler,$pos+1); if(method_exists($object,$method)) $object->$method($sender,$param); - + else throw new TInvalidDataValueException('component_eventhandler_invalid',get_class($this),$name,$handler); } @@ -466,7 +466,7 @@ class TComponent public function addParsedObject($object) { } - + /** * Returns the named behavior object. * The name 'asa' stands for 'as a'. @@ -893,7 +893,7 @@ class TComponentReflection extends TComponent private function reflect() { - $class=new TReflectionClass($this->_className); + $class=new ReflectionClass($this->_className); $properties=array(); $events=array(); $methods=array(); diff --git a/framework/Web/UI/TClientScriptManager.php b/framework/Web/UI/TClientScriptManager.php index f6be8217..cf5f33d4 100644 --- a/framework/Web/UI/TClientScriptManager.php +++ b/framework/Web/UI/TClientScriptManager.php @@ -80,8 +80,8 @@ class TClientScriptManager extends TApplicationComponent * Client-side javascript library packages, loads from SCRIPT_PATH.'/packages.php'; * @var array */ - private static $_pradoPackages; - + private static $_pradoPackages; + /** * Constructor. * @param TPage page that owns this client script manager @@ -259,7 +259,7 @@ class TClientScriptManager extends TApplicationComponent public function getCallbackReference(ICallbackEventHandler $callbackHandler, $options=null) { $options = !is_array($options) ? array() : $options; - $class = new TReflectionClass($callbackHandler); + $class = new ReflectionClass($callbackHandler); $clientSide = $callbackHandler->getActiveControl()->getClientSide(); $options = array_merge($options, $clientSide->getOptions()->toArray()); $optionString = TJavaScript::encode($options); @@ -370,7 +370,7 @@ class TClientScriptManager extends TApplicationComponent /** * Registers a CSS file to be rendered in the page head * - * The CSS files in themes are registered in {@link OnPreRenderComplete onPreRenderComplete} if you want to override + * The CSS files in themes are registered in {@link OnPreRenderComplete onPreRenderComplete} if you want to override * CSS styles in themes you need to register it after this event is completed. * * Example: diff --git a/framework/Web/UI/TTemplateManager.php b/framework/Web/UI/TTemplateManager.php index 505600e8..49873340 100644 --- a/framework/Web/UI/TTemplateManager.php +++ b/framework/Web/UI/TTemplateManager.php @@ -170,7 +170,7 @@ class TTemplate extends TApplicationComponent implements ITemplate { /** * '' - template comments - * '' - HTML comments + * '' - HTML comments * '<\/?com:([\w\.]+)((?:\s*[\w\.]+\s*=\s*\'.*?\'|\s*[\w\.]+\s*=\s*".*?"|\s*[\w\.]+\s*=\s*<%.*?%>)*)\s*\/?>' - component tags * '<\/?prop:([\w\.]+)\s*>' - property tags * '<%@\s*((?:\s*[\w\.]+\s*=\s*\'.*?\'|\s*[\w\.]+\s*=\s*".*?")*)\s*%>' - directives @@ -583,7 +583,7 @@ class TTemplate extends TApplicationComponent implements ITemplate $n=preg_match_all(self::REGEX_RULES,$input,$matches,PREG_SET_ORDER|PREG_OFFSET_CAPTURE); $expectPropEnd=false; $textStart=0; - $stack=array(); + $stack=array(); $container=-1; $matchEnd=0; $c=0; @@ -916,7 +916,7 @@ class TTemplate extends TApplicationComponent implements ITemplate $className=substr($type,$pos+1); else $className=$type; - $class=new TReflectionClass($className); + $class=new ReflectionClass($className); if(is_subclass_of($className,'TControl') || $className==='TControl') { foreach($attributes as $name=>$att) -- cgit v1.2.3