114 * @param mixed $config application configuration. This parameter will be passed as the parameter
115 * to the constructor of the application class.
116 * @return mixed the application instance
117 */
118 public static function createApplication($class, $config = null) {
119 return new $class($config);
120 }
121122 /**
123 * Returns the application singleton or null if the singleton has not been created yet.
124 * @return CApplication the application singleton, null if the singleton has not been created yet.