コード例 #1
0
ファイル: Application.php プロジェクト: nova-framework/system
 /**
  * Refresh the bound request instance in the container.
  *
  * @param  \Nova\Http\Request  $request
  * @return void
  */
 protected function refreshRequest(Request $request)
 {
     $this->instance('request', $request);
     Facade::clearResolvedInstance('request');
 }
コード例 #2
0
ファイル: Start.php プロジェクト: nova-framework/app
     require $path;
 }
 //--------------------------------------------------------------------------
 // Try To Register Again The Config Manager
 //--------------------------------------------------------------------------
 if (CONFIG_STORE == 'database') {
     // Get the Database Connection instance.
     $connection = $app['db']->connection();
     // Get a fresh Config Loader instance.
     $loader = $app->getConfigLoader();
     // Setup Database Connection instance.
     $loader->setConnection($connection);
     // Refresh the Application's Config instance.
     $app->instance('config', $config = new ConfigRepository($loader));
     // Make the Facade to refresh its information.
     Facade::clearResolvedInstance('config');
 } else {
     if (CONFIG_STORE != 'files') {
         throw new \InvalidArgumentException('Invalid Config Store type.');
     }
 }
 //--------------------------------------------------------------------------
 // Load The Application Events
 //--------------------------------------------------------------------------
 $path = app_path() . DS . 'Events.php';
 if (is_readable($path)) {
     require $path;
 }
 //--------------------------------------------------------------------------
 // Load The Application's Route Filters
 //--------------------------------------------------------------------------