You are here

public static function SamlService::create in SAML Authentication 8

Factory method for dependency injection container.

Parameters

\Symfony\Component\DependencyInjection\ContainerInterface $container:

Return value

static

Overrides ContainerInjectionInterface::create

1 string reference to 'SamlService::create'
samlauth.services.yml in ./samlauth.services.yml
samlauth.services.yml

File

src/SamlService.php, line 42
Contains Drupal\samlauth\SamlService.

Class

SamlService
Class SamlService.

Namespace

Drupal\samlauth

Code

public static function create(ContainerInterface $container) {
  $config = samlauth_get_config();
  $auth = new OneLogin_Saml2_Auth($config);
  return new static($auth);
}