public static function getInstance($configFile = null, $mode = self::APP_MODE_PROD) {
        $c = get_called_class();
        if (!isset(self::$_instances[$c])) {
            // Create an instance
            self::$_instances[$c] = new $c($configFile, $mode);
            // Setup application
            self::$_instances[$c]->setup();
        }

        return self::$_instances[$c];
    }
public static function getInstance($configFile = null, $mode = self::APP_MODE_PROD) {
        $c = get_called_class();
        if (!isset(self::$_instances[$c])) {
            // Create an instance
            self::$_instances[$c] = new $c($configFile, $mode);
            // Setup application
            self::$_instances[$c]->setup();
        }

        return self::$_instances[$c];
    }
public static function getInstance ( $ configFile = null , $ mode = self :: APP_MODE_PROD ) { $ c = get_called_class ( ) ; if ( ! isset ( self :: $ _instances [ $ c ] ) ) { // Create an instance self :: $ _instances [ $ c ] = new $ c ( $ configFile , $ mode ) ; // Setup application self :: $ _instances [ $ c ] -> setup ( ) ; } return self :: $ _instances [ $ c ] ; }
Initialize and return App uniq instance

@param array $configFile Application configuration file

@return App
Initialize and return App uniq instance