diff options
author | xue <> | 2005-12-28 20:17:54 +0000 |
---|---|---|
committer | xue <> | 2005-12-28 20:17:54 +0000 |
commit | e8b60312037e54c34a06d6f57d7c21946cf3cd1f (patch) | |
tree | a6f35f5d4bb921998ca306602a33fc03ba47c4b5 /framework/core.php | |
parent | 930c51a6d618d487105cd46c517f36c3b1fe3b44 (diff) |
Modified the way to access application singleton.
IService and IModule interfaces are also adjusted accordingly.
Diffstat (limited to 'framework/core.php')
-rw-r--r-- | framework/core.php | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/framework/core.php b/framework/core.php index 8288f82f..c864dbfa 100644 --- a/framework/core.php +++ b/framework/core.php @@ -56,10 +56,9 @@ interface IModule {
/**
* Initializes the module.
- * @param TApplication the application object
* @param TXmlElement the configuration for the module
*/
- public function init($application,$configuration);
+ public function init($configuration=null);
/**
* @return string ID of the module
*/
@@ -84,10 +83,9 @@ interface IService {
/**
* Initializes the service.
- * @param TApplication the application object
* @param TXmlElement the configuration for the service
*/
- public function init($application,$configuration);
+ public function init($configuration=null);
/**
* @return string ID of the service
*/
@@ -322,7 +320,7 @@ interface IStatePersister * @package System
* @since 3.0
*/
-class TModule extends TComponent implements IModule
+abstract class TModule extends TComponent implements IModule
{
/**
* @var string module id
@@ -332,10 +330,9 @@ class TModule extends TComponent implements IModule /**
* Initializes the module.
* This method is required by IModule and is invoked by application.
- * @param TApplication application
* @param TXmlElement module configuration
*/
- public function init($application,$config)
+ public function init($config=null)
{
}
@@ -377,10 +374,9 @@ abstract class TService extends TComponent implements IService /**
* Initializes the service and attaches {@link run} to the RunService event of application.
* This method is required by IService and is invoked by application.
- * @param TApplication application
* @param TXmlElement module configuration
*/
- public function init($application,$config)
+ public function init($config=null)
{
}
|