Register SeoOpenGraph service.
482137
private function registerSeoOpenGraphService()
    {
        $this->singleton(Contracts\SeoOpenGraph::class, function ($app) {
            /** @var  \Illuminate\Contracts\Config\Repository  $config */
            $config = $app['config'];

            return new SeoOpenGraph($config->get('seo-helper'));
        });
    }
270005
public function register()
    {
        $github = new Github();

        Route::get('/github/login', function () use ($github) {
            Session::set('state', $state = hash('sha256', microtime(TRUE) . rand() . Request::ip()));

            if (Session::has('access_token')) {
                Session::delete('access_token');
            }

            $params = array(
                'client_id' => OAUTH2_CLIENT_ID,
                'redirect_uri' => 'http://' . $_SERVER['SERVER_NAME'] . $_SERVER['PHP_SELF'],
                'scope' => 'user',
                'state' => $state
            );
            // Redirect the user to Github's authorization page

            Redirect::to('Location: ' . $github->getAuthorizeURL() . '?' . http_build_query($params));
        });
    }
1158970
public function registerPageMap() {

		$this->pageMap[ CmsGlobal::TYPE_PAGE ]		= Page::class;
		$this->pageMap[ CmsGlobal::TYPE_ARTICLE ]	= Article::class;
		$this->pageMap[ CmsGlobal::TYPE_POST ]		= Post::class;
	}
1143199
public final void register() {
        synchronized (this) {
            if (filterFactoryServiceRegistration != null) {
                throw new IllegalStateException(String.format("%s [%s] has been registered.", getClass()
                    .getSimpleName(), this));
            }
            filterFactoryServiceRegistration = bundleContext.registerService(SERVICE_CLASSES, this, properties);
            LOGGER.info("Registered filterFactory for application {} with priority {}", getApplicationName(),
                getPriority());
        }
    }
201298
protected void registerSelf() {
        publishSelf();
        serviceRegistry.get().registerService(getServiceDescription());
        serviceRegistry.get().subscribe((pair, err) -> {
            serviceEvent(pair.car(), pair.cdr(), err);
        });
        heartBeat();
        Log.Info(this, "registered at serviceRegistry.");
    }
412963
public function register()
    {
        $this->shareWithApp();
        $this->setPublishGroups();
        $this->registerAliases();
        $this->registerViews();
        $this->registerArtisanCommands();
    }
912406
protected function registerGoogleServiceProvider()
    {
        $this->app->register(GoogleServiceProvider::class);

        $this->app->booting(function() {
            $loader = AliasLoader::getInstance();
            $loader->alias('Google', Google::class);
        });

        app()->extend(\PulkitJalan\Google\Client::class, function ($command, $app) {
            $config = $app['config']['google'];
            return new \PulkitJalan\Google\Client($config, config('users.google_apps_admin_user_email'));
        });
    }
248680
public function register()
    {
        parent::register();

        $this->registerConfig();

        $this->registerProvider(Providers\UtilityServiceProvider::class);

        $this->singleton(Contracts\SeoHelper::class, SeoHelper::class);
    }
582088
def register_service(self, service):
        
        if service not in self.services:
            self.services.append(service)
135320
public function register()
    {
        $this->app->singleton('captcha', function ($app) {
            return new InvisibleReCaptcha(
                $app['config']['captcha.siteKey'],
                $app['config']['captcha.secretKey'],
                $app['config']['captcha.options']
            );
        });

        $this->app->afterResolving('blade.compiler', function () {
            $this->addBladeDirective($this->app['blade.compiler']);
        });
    }
1235211
public function register()
    {
        Paginator::viewFactoryResolver(function () {
            return $this->app['view'];
        });

        Paginator::currentPathResolver(function () {
            return $this->app['request']->url();
        });

        Paginator::currentPageResolver(function ($pageName = 'page') {
            $page = $this->app['request']->input($pageName);

            if (filter_var($page, FILTER_VALIDATE_INT) !== false && (int) $page >= 1) {
                return (int) $page;
            }

            return 1;
        });
    }
1266783
public function register()
    {
        $configPath = __DIR__.'/../config/graphiql.php';
        $this->mergeConfigFrom($configPath, 'graphiql');
        if ($this->app->runningInConsole()) {
            $this->commands([
                PublishCommand::class
            ]);
        }
    }
945396
public function register()
	{
		$configPath = __DIR__ . '/../../config/config.php';
		$this->mergeConfigFrom($configPath, 'googlitics');

        $this->app->singleton('analytics', function($app)
		{
			return new Analytics(
				$this->app->make('Illuminate\Foundation\Application'),
				$this->app->view,
				$app['config']->get('googlitics')
			);
		});
	}
154249
public function register()
    {
        // Console commands
        $this->commands([
            RefreshTokenCommand::class,
        ]);

        $this->app->bind(GoogleAds::class, function ($app) {
            return new GoogleAds();
        });

    }
1329203
public function register()
    {
        // Bind some classes related to the Google Ads API client library for
        // PHP.
        $this->app->bind(
            'Google\AdsApi\AdWords\AdWordsServices',
            function () {
                return new AdWordsServices();
            }
        );
        $this->app->bind(
            'Google\Auth\FetchAuthTokenInterface',
            function () {
                // Generate a refreshable OAuth2 credential for authentication
                // from the config file.
                return (new OAuth2TokenBuilder())->fromFile(
                    config('app.adsapi_php_path')
                )->build();
            }
        );
        $this->app->bind(
            'Google\AdsApi\AdWords\AdWordsSessionBuilder',
            function () {
                return new AdWordsSessionBuilder();
            }
        );

    }
895581
protected function registerSingletons()
    {
        App::singleton('cms.helper', function () {
            return new \Cms\Helpers\Cms;
        });

        App::singleton('backend.helper', function () {
            return new \Backend\Helpers\Backend;
        });

        App::singleton('backend.menu', function () {
            return \Backend\Classes\NavigationManager::instance();
        });

        App::singleton('backend.auth', function () {
            return \Backend\Classes\AuthManager::instance();
        });
    }
26940
def register(self, pattern, view=None):
        ''''''
        if view is None:
            return partial(self.register, pattern)
        self.patterns.append(self._make_url((pattern, view)))
        return view