Register container bindings for the application.

@return void
777548
protected function registerLogBindings()
  {
    $this->singleton('Psr\Log\LoggerInterface', function () {
      $name = Str::slug($this->getNamespaceName());
      if ($this->monologConfigurator) {
        return call_user_func($this->monologConfigurator, new Logger($name));
      } else {
        return new Logger($name, [$this->getMonologHandler()]);
      }
    });
  }
838352
public function register(Container $app): void
    {
        /** @var Collection $writerCollection */
        $writerCollection = $app['transformer.writer.collection'];
        $twigWriter = new Writer\Twig($app[\Twig\Environment::class]);

        $writerCollection['twig'] = $twigWriter;
    }
619442
public function register()
    {
        foreach ($this->modules as $module) {
            if ($aggregator = $module->getAttribute('aggregator')) {
                $this->container->register($aggregator);
            }
        }

        return $this;
    }
1354977
public function register(Container $app)
    {
        $app[DataInterface::class] = $app->factory(Data::class);
        $app[ConfigInterface::class] = $app->factory(FileConfig::class);
    }
1094817
public function register()
    {
        $container = $this->getContainer();
        $config    = $container->get('config');

        $container->share(Client::class)
            ->withArgument(new RawArgument([
                'base_uri' => $config->get('base_uri'),
                'handler'  => $container->get(HandlerStack::class),
            ]));

        if ($config->get('http_adapter') === GuzzleAdapter::class) {
            $container->share(AdapterInterface::class, function () use ($container) {
                return new GuzzleAdapter($container->get(Client::class));
            });
        }

        if ($config->get('http_adapter') === MockAdapter::class) {
            $path = realpath(__DIR__.'/../../tests/fixtures').'/';
            $container->share(AdapterInterface::class, new MockAdapter($path));
        }
    }
422664
public function register()
    {
        // Register 'defaultprofileimage' instance container to our defaultprofileimage object
        $this->app->singleton('defaultprofileimage', function($app)
        {
            return new DefaultProfileImage;
        });

        // Shortcut so developers don't need to add an Alias in app/config/app.php
        $this->app->booting(function()
        {
            $loader = \Illuminate\Foundation\AliasLoader::getInstance();
            $loader->alias('DefaultProfileImage', 'A6digital\Image\Facades\DefaultProfileImage');
        });
    }
152521
protected function booting()
    {
        $this->setInstance();

        $this->bind('Sun\Contracts\Container\Container', $this->getContainer());

        $this->bind('Sun\Contracts\Application', $this);

        $this->config = $this->make('Sun\Support\Config');
    }
435074
public function register(Container $container)
    {
        $container->share(Container::class, $container);

        $container->share(get_class($this->app), $this->app)
            ->bindShared(WindwalkerApplicationInterface::class, get_class($this->app));

        $container->share(Config::class, $this->config);

        $container->prepareSharedObject(PackageResolver::class);

        $this->registerClassAlias();
    }
652615
public function register()
    {
        $container = $this->getContainer();

        /** @var Tapestry $tapestry */
        $tapestry = $container->get(Tapestry::class);
        $configuration = new Configuration(include(__DIR__.'/../../src/Modules/Config/DefaultConfig.php'));

        if ($baseConfigPathName = $this->identifyConfigurationPath($tapestry['currentWorkingDirectory'])) {
            $configuration->merge($this->getConfigurationFromPath($baseConfigPathName));
        }

        if ($envConfigPathName = $this->identifyConfigurationPath($tapestry['currentWorkingDirectory'], $tapestry['environment'])) {
            $configuration->merge($this->getConfigurationFromPath($envConfigPathName));
        }

        $container->share(Configuration::class, $configuration);
    }
628591
public function register() {
		$this->files = new Filesystem;
		$this->registerScanCommand();

		$method = "singleton";
		// Bind the manager as a singleton on the container.
		$this->app->$method('permacon', function($app) {
			
			/**
			 * Construct the actual manager.
			 */
			return new Permacon($app);
		});
	}
679500
public function register()
    {
        $this->app->singleton(SecurityContext::class);
        $this->app->bind(RepositoryFactory::class, function(Container $container){
            return
                new ContainerBindingRepositoryFactory($container,
                    new ConfigurationRepositoryFactory($container,
                        new DefaultRepositoryFactory($container)
                    )
                );
        });
    }
690980
public function register(Container $container)
    {
        $this->registerViewConfig($container);
        $this->registerLoaderServices($container);
        $this->registerEngineServices($container);
        $this->registerMustacheTemplatingServices($container);
        $this->registerTwigTemplatingServices($container);
        $this->registerViewServices($container);
    }
635503
public function register()
    {
        $this->container['config']->addLocation($this->container->basePath().'/dev/config');

        foreach ($this->container['config']->get('app.providers') as $provider) {
            $this->container->addProvider($provider);
        }
    }
1225952
public function registerCoreContainerAliases()
    {
        $aliases = [
            'app'     => [\Very\Application::class, \Illuminate\Container\Container::class],
            'config'  => [\Very\Config::class],
            'cookie'  => [\Very\Cookie\CookieJar::class],
            'logger'  => [\Very\Logger::class],
            'router'  => [\Very\Routing\Router::class],
            'session' => [\Very\Session\SessionManager::class],
            'view'    => [\Very\View::class],
        ];

        foreach ($aliases as $key => $aliase) {
            foreach ($aliase as $alias) {
                $this->alias($key, $alias);
            }
        }
    }
212778
protected function registerCommands()
    {
        $this->add(new \Daedalus\Command\DumpContainerCommand($this->kernel->getContainer()));
        $this->add(new \Daedalus\Command\HelpCommand($this->kernel->getContainer()));
    }
1002512
public static function boot() : void
    {
        $container = self::getContainer();
        $container->singleton('app', $container);

        Facade::setFacadeApplication($container);
    }
108268
public function registerCommands()
    {
        $commands = (array) $this->get('console.commands');

        foreach ($commands as $command) {
            if ($command === false) {
                continue;
            }

            if (is_string($command)) {
                $command = $this->container->createObject($command);
            }

            $this->addCommand($command);
        }
    }