register() public method

Register the service provider.
public register ( ) : void
return void
Esempio n. 1
0
 /**
  * Register the service provider.
  *
  * @return void
  */
 public function register()
 {
     parent::register();
     $this->app->singleton('api.router.adapter', function ($app) {
         return new LumenAdapter($app, new StdRouteParser(), new GcbDataGenerator(), 'FastRoute\\Dispatcher\\GroupCountBased');
     });
 }
Esempio n. 2
0
 /**
  * Register the service provider.
  *
  * @return void
  */
 public function register()
 {
     parent::register();
     $reflection = new ReflectionClass($this->app);
     $this->app->instance('app.middleware', $this->gatherAppMiddleware($reflection));
     $this->addRequestMiddlewareToBeginning($reflection);
     $this->app->singleton('api.router.adapter', function ($app) {
         return new LumenAdapter($app, new StdRouteParser(), new GcbDataGenerator(), 'FastRoute\\Dispatcher\\GroupCountBased');
     });
 }
 /**
  * Register the service provider.
  *
  * @return void
  */
 public function register()
 {
     parent::register();
     $this->registerRouterAdapter();
 }