Register the internal dispatcher.

@return void
978120
public function registerDispatcher()
    {
        $this->app->singleton('api.dispatcher', function ($app) {
            $dispatcher = new Dispatcher(
                $app, $app['files'], $app['Dingo\Api\Routing\Router'], $app[Auth::class]
            );

            $dispatcher->setSubtype($this->config('subtype'));
            $dispatcher->setStandardsTree($this->config('standardsTree'));
            $dispatcher->setPrefix($this->config('prefix'));
            $dispatcher->setDefaultVersion($this->config('version'));
            $dispatcher->setDefaultDomain($this->config('domain'));
            $dispatcher->setDefaultFormat($this->config('defaultFormat'));

            return $dispatcher;
        });
    }
1283089
protected function registerFatalHandler()
    {
        $error = $this;

        // When shutdown, the current working directory will be set to the web
        // server directory, store it for later use
        $cwd = getcwd();

        register_shutdown_function(function () use ($error, $cwd) {
            $e = error_get_last();
            if (!$e || !in_array($e['type'], array(E_ERROR, E_CORE_ERROR, E_COMPILE_ERROR, E_PARSE))) {
                // No error or not fatal error
                return;
            }

            ob_get_length() && ob_end_clean();

            // Reset the current working directory to make sure everything work as usual
            chdir($cwd);

            $exception = new \ErrorException($e['message'], $e['type'], 0, $e['file'], $e['line']);

            if ($error->triggerHandler('fatal', $exception)) {
                // Handled!
                return;
            }

            // Fallback to error handlers
            if ($error->triggerHandler('error', $exception)) {
                // Handled!
                return;
            }

            // Fallback to internal error Handlers
            $error->internalHandleException($exception);
        });
    }
921630
public function dispatch()
	{
		if(!self::$isDispatched){
		    if (PHP_SAPI == 'cli') {
		        $this->dispatchCli();
		    } else {
                $this->dispatchHttp();
		    }
            self::$isDispatched = true;
        }
    }
1326504
protected function registering()
    {
        $this->app->bindShared(ServiceShortCuts::RESOLVER_SERVICE, function () {
            return new Resolver($this->app);
        });

        $this->app->bindShared(ServiceShortCuts::GHOST_SERVICE, function () {
            return new GhostServices($this->app);
        });

        $this->app->bind(ServiceShortCuts::CORE_INITIALIZED, true);

        $this->app->booting(function () {
            $loader = AliasLoader::getInstance();

            foreach ($this->aliases as $facade => $facadeClass) {
                $loader->alias($facade, $facadeClass);
            }
        });
    }
1109415
private function registerCommands()
    {
        //scheduled:summary
        $this->app->bindShared('command.scheduled.summary', function (Application $app) {
            return $app->make('Indatus\Dispatcher\Commands\ScheduleSummary');
        });

        //scheduled:make
        $this->app->bindShared('command.scheduled.make', function (Application $app) {
            return $app->make('Indatus\Dispatcher\Commands\Make');
        });

        //scheduled:run
        $this->app->bindShared('command.scheduled.run', function (Application $app) {
            return $app->make('Indatus\Dispatcher\Commands\Run');
        });

        $this->commands($this->provides());
    }
1213680
public function register()
    {
        // Bind the Class
        $this->app->bind('helper', function () {
            return $this->app->make(Helper::class);
        });

        // Register an Alias of the Facade
        $this->app->booting(function () {
            $loader = AliasLoader::getInstance();
            $loader->alias('Helper', HelperFacade::class);
        });
    }
774055
public function register(IURLDispatcher $dispatcher, $index = 10) {
        $this->dispatchers [ $index ] [] = $dispatcher;
        ksort($this->dispatchers, SORT_NUMERIC);
    }
182240
protected function registerDataGrid()
    {
        $this->app->singleton('datagrid', function ($app) {
            $request = $app->request;

            return new Manager($request);
        });
    }
316985
public function initDispatcher()
    {
        $this->di->set('dispatcher', function() {
            $dispatcher = new Dispatcher();

            /**
             * @var \Phalcon\Events\Manager $eventsManager
             */
            $eventsManager = $this->di->getShared('eventsManager');
            $eventsManager->attach(
                'dispatch:beforeException',
                (new ExceptionListener())->beforeException()
            );

            $dispatcher->setEventsManager($eventsManager);

            return $dispatcher;
        });
    }
594311
public function register()
    {
        $this->app->singleton(Dispatcher::class, function ($app) {
            return new Dispatcher($app, function ($connection = null) use ($app) {
                return $app[QueueFactoryContract::class]->connection($connection);
            });
        });

        $this->app->alias(
            Dispatcher::class, DispatcherContract::class
        );

        $this->app->alias(
            Dispatcher::class, QueueingDispatcherContract::class
        );
    }
83181
public function dispatch(): void
    {
        $dispatcher = new Dispatcher();

        if ($this->connector) {
            $dispatcher->add($this->listenConnector());
        }

        if ($this->exchangeWorkersData) {
            $dispatcher->add($this->listenWorkers());
        }

        $dispatcher->dispatch();
    }
595193
public function register()
    {
        $this->registerAlias();

        $this->app->bind('data.provider', function ($app) {
            return new DataProvider($this->resolveRequestData($app['request']));
        });
    }
1133648
protected function registerHandler()
	{
		$this->app['exception'] = $this->app->share(function($app)
		{
			return new Handler($app, $app['exception.plain'], $app['exception.debug']);
		});
	}
673608
protected function registerManager()
    {
        Zilf::$container->register(
            'queue', function () {
                // Once we have an instance of the queue manager, we will register the various
                // resolvers for the queue connectors. These connectors are responsible for
                // creating the classes that accept queue configs and instantiate queues.
                return tap(
                    new QueueManager(), function ($manager) {
                        $this->registerConnectors($manager);
                    }
                );
            }
        );
    }
989708
public function register()
	{

		$this->app['irc'] = $this->app->share(function($app)
		{
			return new \Tjbenator\Irc\Irc($app);
		});

		$this->app->booting(function()
		{
			$loader = \Illuminate\Foundation\AliasLoader::getInstance();
			$loader->alias('Irc', 'Tjbenator\Irc\Facades\Irc');
		});

		$this->registerCommands();
	}
643734
protected function registerEventRebindHandler()
    {
        $this->app->rebinding('events', function ($app, $dispatcher) {
            if (! $app->resolved('auth')) {
                return;
            }

            if (method_exists($guard = $app['auth']->guard(), 'setDispatcher')) {
                $guard->setDispatcher($dispatcher);
            }
        });
    }
36814
protected function registerManager(): void
    {
        $this->app->singleton('algolia', function (Container $app) {
            $config = $app['config'];
            $factory = $app['algolia.factory'];

            return new AlgoliaManager($config, $factory);
        });

        $this->app->alias('algolia', AlgoliaManager::class);
    }