Register a service provider with the application.

@param  \Illuminate\Support\ServiceProvider|string  $provider
@return \Illuminate\Support\ServiceProvider
488161
public function register($provider)
    {
        if (! $provider instanceof ServiceProvider) {
            $provider = new $provider($this);
        }

        if (array_key_exists($providerName = get_class($provider), $this->loadedProviders)) {
            return;
        }

        $this->loadedProviders[$providerName] = true;

        if (method_exists($provider, 'register')) {
            $provider->register();
        }

        if (method_exists($provider, 'boot')) {
            return $this->call([$provider, 'boot']);
        }
    }
1091981
public function registerDeferredProvider($provider, $service = null)
    {
        // Once the provider that provides the deferred service has been registered we
        // will remove it from our local list of the deferred services with related
        // providers so that this container does not try to resolve it out again.
        if ($service) {
            unset($this->deferredServices[$service]);
        }
        $this->registerProvider($instance = new $provider($this));
    }
1128580
public function register(string $module)
    {
        $dir = $this->getBase() . $this->getDir() . rtrim($module, '*');

        if (is_dir($dir)) {
            return $this->fromPath($module);
        } else {
            return $this->fromProvider($module);
        }
    }
1140866
protected function getConfigFromProvider( $provider){
        $service = sprintf( self::API_CONNECTION_DDNS_CONFIG, $provider);
        $rest = $this->getService( $service);
        $rest->GET();

        return $rest->getResult( models\Connection\DynDns\Config::class);
    }
522654
public function register(ServiceProviderInterface $provider, array $values = [])
    {
        $this->providers[] = $provider;

        parent::register($provider, $values);

        return $this;
    }
639175
protected function fromProvider($provider)
    {
        $provider = IOC::resolve($provider);
        $module = $provider->create();
        $this->add($provider->getName(), $module);
        return $module;
    }
498997
private function registerProvider()
    {
        $app = $this->app;

        // Pick the correct service provider for the current verison of Laravel
        $this->provider = (version_compare($app::VERSION, '5.0', '<'))
            ? new ImgurServiceProviderLaravel4($app)
            : new ImgurServiceProviderLaravel5($app);
    }
896241
protected function registerServiceProvider($serviceProvider) {
        $serviceProvider = $this->ensureProviderIsObject($serviceProvider);

        if (!($serviceProvider instanceof Contracts\ServiceProvider)) {
            throw new InvalidConfigException('Service provider should be an instance of ' . ServiceProvider::class);
        } elseif ($serviceProvider instanceof Contracts\DelayedServiceProvider) {
            $this->addDelayedServiceProvider($serviceProvider);
        } else {
            $serviceProvider->register();
        }
    }
692592
protected function loadEagerServiceProvider($provider, array $options)
    {
        if (!$options['eager']) {
            return;
        }

        $instance = Arr::get($options, 'instance', $provider);

        $this->app->register($instance);
    }
115481
public function registerProvider(Provider $provider)
    {
        $provider->register($this);
        
        $this->container->addProvider($provider);
        
        return $this;
    }
460364
protected function registerJWTProvider()
    {
        $this->app->singleton('lia.jwt.provider.jwt', function ($app) {
            $secret = $this->config('secret');
            $algo = $this->config('algo');
            $provider = $this->config('providers.jwt');

            return new $provider($secret, $algo);
        });
    }
385806
public function getProvider($provider)
    {
        // Check if an instance has already been initiated. If not
        // build it and then add to the providers array.
        if (!isset($this->providers[$provider])) {
            $this->addProvider($provider);
        }

        return $this->providers[$provider];
    }
3876
public function addResourceProvider(ResourceProvider $provider)
    {
        $this->loaded && $this->loaded->__invoke();

        $this->resourceProviders[] = $provider;

        return $this;
    }
92619
public function addProvider($provider)
    {
        if ($provider instanceof Provider) {
            $this->providers[] = $provider;
        }

        if (is_array($provider)) {
            $this->providers[] = new Provider(
                $provider['endpoint'],
                $provider['schemes'],
                $provider['url'],
                $provider['name']
            );
        }
    }
561719
public function providers(array $providers = [])
    {
        foreach ($providers as $provider) {
            $this->app->register(new $provider($this->app));
        }

        return $this;
    }
968559
public function registerProvider(ProviderInterface $provider)
    {
        if (null !== $provider) {
            $this->providers[$provider->getName()] = $provider;
        }

        return $this;
    }
1300536
public function registerProviders(array $providers = []): self
    {
        foreach ($providers as $provider) {
            $this->registerProvider($provider);
        }

        return $this;
    }