Register the service provider and alias
764831
public function register()
    {
        $this->app->singleton('hipchat', function ($app) {
            return new Client(config('hipchat.api_token'), config('hipchat.server_url'));
        });

        $this->app->alias(Bestit\HipChat\Facade\HipChat::class, 'HipChat');
    }
188110
public function register()
    {

        if ('LaravelCommode\Common\CommodeCommonServiceProvider' !== get_class($this)) {
            /**
             * Prepare service
             */
            $this->prepareService();

            /**
             * Bind app's 'booting' event resolving, aliases and launching methods
             */
            $this->app->booting($this->getResolver()->makeClosure(function () {

                if (count($this->aliases) > 0) {
                    $loader = AliasLoader::getInstance();

                    foreach ($this->aliases as $facadeName => $facadeClass) {
                        $loader->alias($facadeName, $facadeClass);
                    }
                }

                $this->launchClosure();
            }));

        }

        /**
         * Register service
         */
        $this->registering();
    }
581072
protected function registerClassAliases()
    {
        $serviceAliases = [
            Request::class => 'Dingo\Api\Contract\Http\Request',
            'api.dispatcher' => Dispatcher::class,
            'api.http.validator' => 'Dingo\Api\Http\RequestValidator',
            'api.http.response' => 'Dingo\Api\Http\Response\Factory',
            'api.router' => 'Dingo\Api\Routing\Router',
            'api.router.adapter' => 'Dingo\Api\Contract\Routing\Adapter',
            'api.auth' => Auth::class,
            'api.limiting' => 'Dingo\Api\Http\RateLimit\Handler',
            'api.transformer' => TransformerFactory::class,
            'api.url' => 'Dingo\Api\Routing\UrlGenerator',
            'api.exception' => [ExceptionHandler::class, 'Dingo\Api\Contract\Debug\ExceptionHandler'],
        ];

        foreach ($serviceAliases as $key => $aliases) {
            foreach ((array) $aliases as $alias) {
                $this->app->alias($key, $alias);
            }
        }
    }
538979
protected function registerProviders()
    {
        /** @var Container $container */
        $container = $this->getContainer();

        // Register Aliases
        $aliases = (array) $this->get('di.aliases');

        foreach ($aliases as $alias => $target) {
            $container->alias($alias, $target);
        }

        $container->registerServiceProvider(new SystemProvider($this, $this->config));

        $providers = (array) $this->config->get('providers');

        foreach ($providers as $interface => &$provider) {
            if ($provider === false) {
                continue;
            }

            if (is_subclass_of($provider, ServiceProviderInterface::class)) {
                // Handle provider
                if ($provider instanceof ClassMeta || (is_string($provider) && class_exists($provider))) {
                    $provider = $container->newInstance($provider);
                }

                if ($provider === false) {
                    continue;
                }

                $container->registerServiceProvider($provider);

                if ($provider instanceof BootableProviderInterface
                    || method_exists($provider, 'boot')) {
                    $provider->boot($container);
                }
            } else {
                // Handle Service
                if (is_numeric($interface)) {
                    $container->prepareSharedObject($provider);
                } else {
                    $container->bindShared($interface, $provider);
                }
            }
        }

        foreach ($providers as $provider) {
            if ($provider === false) {
                continue;
            }

            if (is_subclass_of($provider, ServiceProviderInterface::class)
                && (
                    $provider instanceof BootableDeferredProviderInterface
                    || method_exists($provider, 'bootDeferred')
                )) {
                $provider->bootDeferred($container);
            }
        }
    }
909175
protected function registerConfiguredAliases()
    {
        $aliases = $this->getCoreConfig('aliases', []);

        if (empty($aliases)) {
            // @codeCoverageIgnoreStart
            return $this;
            // @codeCoverageIgnoreEnd
        }

        $aliasLoader = AliasLoader::getInstance();

        foreach ($aliases as $alias => $binding) {
            $aliasLoader->alias($alias, $binding);
        }

        return $this;
    }
393617
public function register()
    {
        // register class aliases
        $loader = AliasLoader::getInstance();
        $loader->alias('PageBuilder', PageBuilderFacade::class);

        // register container aliases
        $this->app->alias('pageBuilder', PageBuilderFactory::class);
        $this->app->alias('pageBuilder', PageBuilder::class);
    }
38993
private function registerBaseFacades()
    {
        Facade::clearResolvedInstances();

        Facade::setFacadeApplication($this);

        AliasLoader::getInstance($this->make('config')->get('app.aliases'))->register();
    }
801462
protected function registerBaseServiceProviders()
    {
        $providers = [
            AliasesServiceProvider::class,
            \Collective\Html\HtmlServiceProvider::class,
            BreadcrumbsServiceProvider::class,
            AdminServiceProvider::class,
        ];

        /* Workaround to allow use ServiceProvider-based configurations in old fashion */
        if (is_file(app_path('Providers/AdminSectionsServiceProvider.php'))) {
            $providers[] = $this->app->getNamespace().'Providers\\AdminSectionsServiceProvider';
        }

        $manifestPath = $this->app->bootstrapPath().'/cache/sleepingowladmin-services.php';

        (new ProviderRepository($this->app, new Filesystem(), $manifestPath))->load($providers);
    }
1148148
public function register()
    {
        $loader = \Illuminate\Foundation\AliasLoader::getInstance();
        // Register the alias.
        $loader->alias('Identicon', \Identicon\Identicon::class);
    }
782650
public function register()
    {
        $this->config = ConfigurationLoader::load($this->app);

        $this->registerServices();

        // If we want Laravel's Redis API to use Sentinel, we'll return an
        // instance of the RedisSentinelManager when requesting the "redis"
        // service:
        if ($this->config->shouldOverrideLaravelRedisApi) {
            $this->registerOverrides();
        }
    }
175495
private function loadServiceProvider()
    {
        \Tiga\Framework\Facade\Facade::setFacadeContainer($this);

        // Available Provider
        $providers = $this['config']->get('provider');

        $providers = array_unique($providers);

        foreach ($providers as $provider) {
            $instance = new $provider($this);
            $instance->register();
        }

        // Aliases
        $aliases = $this['config']->get('alias');

        $aliases = array_unique($aliases);

        $aliasMapper = \Tonjoo\Almari\AliasMapper::getInstance();

        $aliasMapper->classAlias($aliases);
    }
1009300
protected function registerFacadesAliases(): void
    {
        $loader = AliasLoader::getInstance();

        foreach ((array) $this->facades as $facade => $aliases) {
            foreach ((array) $aliases as $alias) {
                $loader->alias($alias, $facade);
            }
        }
    }
1080340
def register(self, alias, uri):
        
        # TODO: do we want to constrain the valid alias names.
        if isinstance(uri, dict):
            id = uri.get('id', alias)
            self.resolver.store[id] = uri
            uri = id
        self.aliases[alias] = uri
663366
public function register() {

		$this->app->bind( Attributes::class, Attr::class );

		$this->app->alias( Attributes::class, 'attr' );
	}
1184482
public function register()
    {
        $source_config = __DIR__.'/../../config/fractal.php';
        $this->mergeConfigFrom($source_config, 'fractal');

        $this->app->singleton('fractal', function ($app) {

            // retrieves configurations

            $autoload = $app['config']->get('fractal.autoload');
            $input_key = $app['config']->get('fractal.input_key');
            $exclude_key = $app['config']->get('fractal.exclude_key');
            $serializer = $app['config']->get('fractal.serializer');

            // creating fractal manager instance
            $manager = new Manager();
            $factalNamespace = 'League\\Fractal\\Serializer\\';

            $loadSerializer = (class_exists($factalNamespace.$serializer)) ?
                $factalNamespace.$serializer : $serializer;

            $manager->setSerializer(new $loadSerializer());

            if ($autoload === true and $includes = $app['request']->input($input_key)) {
                $manager->parseIncludes($includes);
            }

            if ($app['request']->has($exclude_key)) {
                $manager->parseExcludes($app['request']->input($exclude_key));
            }

            return new FractalServices($manager, $app['app']);
        });
        $this->app->alias('fractal', FractalServices::class);

        // register our command here
        $this->app->singleton('command.transformer.generate', function ($app) {
            return new TransformerGeneratorCommand($app['config'], $app['view'], $app['files'], $app);
        });

        $this->commands('command.transformer.generate');
    }
317205
public function register()
    {
        // Register the Sentinel Service Provider
        $this->app->register(SentinelServiceProvider::class);

        // Load the Sentry and Hashid Facade Aliases
        $loader = AliasLoader::getInstance();
        $loader->alias('Activation', Activation::class);
        $loader->alias('Reminder', Reminder::class);
        $loader->alias('Sentinel', Sentinel::class);
    }
934392
protected function registerProviders(): void
    {
        foreach ($this->providers as $provider) {
            $this->app->register($provider);
        }
    }