本文整理匯總了PHP中Barryvdh\Debugbar\LaravelDebugbar::setHttpDriver方法的典型用法代碼示例。如果您正苦於以下問題:PHP LaravelDebugbar::setHttpDriver方法的具體用法?PHP LaravelDebugbar::setHttpDriver怎麽用?PHP LaravelDebugbar::setHttpDriver使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Barryvdh\Debugbar\LaravelDebugbar
的用法示例。
在下文中一共展示了LaravelDebugbar::setHttpDriver方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: register
/**
* Register the service provider.
*
* @return void
*/
public function register()
{
$configPath = __DIR__ . '/../config/debugbar.php';
$this->mergeConfigFrom($configPath, 'debugbar');
$this->app->alias('DebugBar\\DataFormatter\\DataFormatter', 'DebugBar\\DataFormatter\\DataFormatterInterface');
$this->app->singleton('debugbar', function ($app) {
$debugbar = new LaravelDebugbar($app);
$sessionManager = $app['session'];
$httpDriver = new SymfonyHttpDriver($sessionManager);
$debugbar->setHttpDriver($httpDriver);
return $debugbar;
});
$this->app->alias('debugbar', 'Barryvdh\\Debugbar\\LaravelDebugbar');
$this->app['command.debugbar.clear'] = $this->app->share(function ($app) {
return new Console\ClearCommand($app['debugbar']);
});
$this->commands(array('command.debugbar.clear'));
}
示例2: setHttpDriver
/**
* Sets the HTTP driver
*
* @param \DebugBar\HttpDriverInterface $driver
* @static
*/
public static function setHttpDriver($driver)
{
//Method inherited from \DebugBar\DebugBar
return \Barryvdh\Debugbar\LaravelDebugbar::setHttpDriver($driver);
}