Register the bindings.

@param \Illuminate\Contracts\Foundation\Application $app

@return void
480292
protected function registerBindings(Application $app) {
        $app->bind('bitbucket.connection', function ($app) {
            $manager = $app['bitbucket'];
            return $manager->connection();
        });
        $app->alias('bitbucket.connection', Api::class);
    }
888403
public function register() {
        $this->registerAuthFactory($this->app);
        $this->registerBitbucketFactory($this->app);
        $this->registerManager($this->app);
        $this->registerBindings($this->app);
    }
895587
public function register(): void
    {
        ! $this->app->runningInConsole() || $this->registerCommands($this->commands);
        ! $this->app->runningInConsole() || $this->registerCommands($this->devCommands);
    }
1124586
public function register()
    {
        $appPath = __DIR__ . DIRECTORY_SEPARATOR;
        $path = $appPath . ".." . DIRECTORY_SEPARATOR;
        $path .= "Helpers" . DIRECTORY_SEPARATOR . "*.php";

        foreach (glob($path) as $filename) {
            require_once $filename;
        }
    }
389411
public function register(Application $app)
    {
        /** @var ApplicationConfiguration $config */
        $config = $app['config'];

        $app['translator.locale'] = $config->getTranslator()->getLocale();

        $app['translator'] = $app->share(
            function ($app) {
                $translator = new Translator();
                $translator->setLocale($app['translator.locale']);

                return $translator;
            }
        );
    }
496780
protected function registerBindings()
    {
        $binding = config('binding')?: [];

        foreach($binding as $contract => $implementation) {
            $this->bind($contract, $implementation);
        }
    }
223315
public function register(Application $app)
    {
        parent::register($app);
        $app['cache'] = $app->share(function ($app) {
            $config = $app['config'];
            if (! array_key_exists('cache.driver', $config)) {
                return new ArrayCache();
            }
            switch ($config['cache.driver']) {
                case 'array':
                    return new ArrayCache();
                case 'redis':
                    $cache = new RedisCache();
                    if (isset($config['cache.redis'])) {
                        $redis = new \Redis();
                        $redis->connect($config['cache.redis']['host'], $config['cache.redis']['port']);
                        $cache->setRedis($redis);
                    } else {
                        $cache->setRedis($app['redis']);
                    }
                    return $cache;
                case 'xcache':
                    return new XcacheCache();
                default:
                    throw new \RuntimeException('Unknown cache driver: '.$config['cache.driver']);
            }
        });
    }
996518
protected function registerCustomBindings(): void
    {
        $entityServiceFactory = $this->app->make(IEntityServiceFactory::class);

        foreach (config('laravel_entity_services.bindings') as $className => $entityService) {
            $entityServiceFactory->register($className, $entityService);
        }
    }
1052572
public function registerTranslations($app)
    {
        if(!isset($app->get('i18n')->translations['tecnocen/oauth2/*'])) {
            $app->get('i18n')->translations['tecnocen/oauth2/*'] = [
                'class'    => PhpMessageSource::class,
                'basePath' => __DIR__ . '/messages',
                'fileMap' => [
                    'tecnocen/oauth2/oauth2server' => 'oauth2server.php',
                ],
            ];
        }
    }
284762
public function register(Application $app)
    {
        parent::register($app);

        $app->register(
            new \Silex\Provider\DoctrineServiceProvider(),
            ['db.options' => $app['config']['db.options']]
        );
        $app->register(
            new DoctrineOrmServiceProvider(),
            $app['config']['orm.options']
        );

        if (getenv('MIGRATION_COMMANDS')) {
            $app->register(new MigrationServiceProvider(), [
                'db.migrations.path' =>$app['config']['migrations.directory'],
            ]);
        }

        $app['orm.em'] = $app->extend('orm.em', function(EntityManagerInterface $em) use($app) {
            if (file_exists(APP_PATH.'/vendor/apitude/apitude/src/Annotations/APIAnnotations.php')) {
                AnnotationRegistry::registerFile(APP_PATH.'/vendor/apitude/apitude/src/Annotations/APIAnnotations.php');
            }
            /** @var Configuration $config */
            $config = $em->getConfiguration();
            $config->setMetadataCacheImpl($app['cache']);
            $config->addCustomHydrationMode('simple', SimpleHydrator::class);

            /** @var MappingDriverChain $driver */
            $driver = $config->getMetadataDriverImpl();

            // gedmo initialization
            $reader = new AnnotationReader();
            $cache = new CachedReader($reader, $app['cache']);
            DoctrineExtensions::registerAbstractMappingIntoDriverChainORM(
                $driver,
                $cache
            );

            return $em;
        });
    }
369749
public function register()
    {
        $this->prepareResources();
        $this->registerGroups();
        $this->registerUsers();
        $this->registerSettings();
        $this->registerLog();
        $this->registerVisits();
        $this->registerJobs();
        $this->registerBase();
        $this->registerToAppConfig();
        $this->registerMiddleware();
    }
621618
public function register()
    {
        $this->registerRevisionRepository();
        $this->registerUserRepository();
        $this->registerGroupRepository();
        $this->registerCredentials();

        $this->registerLoginController();
        $this->registerRegistrationController();
        $this->registerResetController();
        $this->registerActivationController();
    }
851804
public function bindings($app)
	{
		$app->bind('CoandaCMS\Coanda\Urls\Repositories\UrlRepositoryInterface', 'CoandaCMS\Coanda\Urls\Repositories\Eloquent\EloquentUrlRepository');

		$search_provider = $this->config->get('coanda::coanda.search_provider');

		if (class_exists($search_provider))
		{
			$app->bind('CoandaCMS\Coanda\Search\CoandaSearchProvider', $search_provider);
		}
		else
		{
			$app->bind('CoandaCMS\Coanda\Search\CoandaSearchProvider', 'CoandaCMS\Coanda\Search\Basic\CoandaBasicSearchProvider');
		}

		// Let the module output any bindings
		foreach ($this->modules as $module)
		{
			$module->bindings($app);
		}
	}
1158917
public function register()
  {
    $events = $this->register;

    foreach($events as $name => $event) {
      Events::listen($name, $event);
    }
  }
929225
public function init(Application $application)
    {
        $application->addService('staticController', new StaticControllerService());
        $application->any(':all', $application->getService('staticController'));
    }
1024064
public function register(Application $app)
    {
        $app['social-login.controller'] = $app->share(function ($app) {
            $config = $app['config']->load('social-login');

            $controller = new SocialLoginController;
            $controller
                ->setSocialLoginService($app['social-login.service'])
                ->setConfig($config)
                ->setServiceFactory(new ServiceFactory())
                ->setSession($app['session']);

            return $controller;
        });

        $app['social-login.mapper'] = $app->share(function ($app) {
            return new SocialLoginMapper($app['db'], new SocialLoginEntity);
        });

        $app['social-login.service'] = $app->share(function ($app) {
            $service = new SocialLoginService;
            $service->setUserService($app['user.service'])
                ->setSocialLoginMapper($app['social-login.mapper'])
                ->setOAuthStorage($app['oauth.storage']);

            return $service;
        });

        $app->get('/social-login/{provider}', 'social-login.controller:login')
            ->bind('social-login-auth');

        $app->get('/social-login/{provider}/link', 'social-login.controller:link')
            ->bind('social-link-auth');

        $app->get('/social-login/{provider}/callback', 'social-login.controller:callback')
            ->bind('social-login-callback');

        $this->setFirewalls($app);
    }
1343460
public function registerStorageBindings(Application $app)
    {
        $provider = $this;

        $app->singleton(FluentAccessToken::class, function () use ($provider) {
            $storage = new FluentAccessToken($provider->app['db']);
            $storage->setConnectionName($provider->getConnectionName());

            return $storage;
        });

        $app->singleton(FluentAuthCode::class, function () use ($provider) {
            $storage = new FluentAuthCode($provider->app['db']);
            $storage->setConnectionName($provider->getConnectionName());

            return $storage;
        });

        $app->singleton(FluentClient::class, function ($app) use ($provider) {
            $limitClientsToGrants = $app['config']->get('oauth2.limit_clients_to_grants');
            $storage = new FluentClient($provider->app['db'], $limitClientsToGrants);
            $storage->setConnectionName($provider->getConnectionName());

            return $storage;
        });

        $app->singleton(FluentRefreshToken::class, function () use ($provider) {
            $storage = new FluentRefreshToken($provider->app['db']);
            $storage->setConnectionName($provider->getConnectionName());

            return $storage;
        });

        $app->singleton(FluentScope::class, function ($app) use ($provider) {
            $limitClientsToScopes = $app['config']->get('oauth2.limit_clients_to_scopes');
            $limitScopesToGrants = $app['config']->get('oauth2.limit_scopes_to_grants');
            $storage = new FluentScope($provider->app['db'], $limitClientsToScopes, $limitScopesToGrants);
            $storage->setConnectionName($provider->getConnectionName());

            return $storage;
        });

        $app->singleton(FluentSession::class, function () use ($provider) {
            $storage = new FluentSession($provider->app['db']);
            $storage->setConnectionName($provider->getConnectionName());

            return $storage;
        });
    }