From 7b38480de52c1d042ea542e2d06913a8c9b645fc Mon Sep 17 00:00:00 2001 From: xue <> Date: Fri, 17 Feb 2006 05:19:25 +0000 Subject: Add TApplicationComponent class and adjusted the relevant classes. --- framework/core.php | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) (limited to 'framework/core.php') diff --git a/framework/core.php b/framework/core.php index 93d19002..c3a14c5d 100644 --- a/framework/core.php +++ b/framework/core.php @@ -21,6 +21,10 @@ define('PRADO_DIR',dirname(__FILE__)); * Includes TComponent definition */ require_once(PRADO_DIR.'/TComponent.php'); +/** + * Includes TApplicationComponent definition + */ +require_once(PRADO_DIR.'/TApplicationComponent.php'); /** * Includes exception definitions */ @@ -264,7 +268,7 @@ interface IStatePersister * @package System * @since 3.0 */ -abstract class TModule extends TComponent implements IModule +abstract class TModule extends TApplicationComponent implements IModule { /** * @var string module id @@ -295,14 +299,6 @@ abstract class TModule extends TComponent implements IModule { $this->_id=$value; } - - /** - * @return TApplication current application instance - */ - public function getApplication() - { - return Prado::getApplication(); - } } /** @@ -316,7 +312,7 @@ abstract class TModule extends TComponent implements IModule * @package System * @since 3.0 */ -abstract class TService extends TComponent implements IService +abstract class TService extends TApplicationComponent implements IService { /** * @var string service id @@ -354,14 +350,6 @@ abstract class TService extends TComponent implements IService public function run() { } - - /** - * @return TApplication current application instance - */ - public function getApplication() - { - return Prado::getApplication(); - } } /** -- cgit v1.2.3