public function UserAuthenticator::__construct in Social Auth 3.x
Same name and namespace in other branches
- 8.2 src/User/UserAuthenticator.php \Drupal\social_auth\User\UserAuthenticator::__construct()
Constructor.
Parameters
\Drupal\Core\Session\AccountProxyInterface $current_user: Used to get current active user.
\Drupal\Core\Messenger\MessengerInterface $messenger: Used to display messages to user.
\Drupal\Core\Logger\LoggerChannelFactoryInterface $logger_factory: Used for logging errors.
\Drupal\social_auth\User\UserManager $user_manager: The Social API user manager.
\Drupal\social_auth\SocialAuthDataHandler $data_handler: Used to interact with session.
\Drupal\Core\Config\ConfigFactoryInterface $config_factory: Used for accessing Drupal configuration.
\Drupal\Core\Routing\RouteProviderInterface $route_provider: Used to check if route path exists.
\Symfony\Component\EventDispatcher\EventDispatcherInterface $event_dispatcher: Used for dispatching social auth events.
Overrides UserAuthenticator::__construct
File
- src/
User/ UserAuthenticator.php, line 72
Class
- UserAuthenticator
- Manages Drupal authentication tasks for Social Auth.
Namespace
Drupal\social_auth\UserCode
public function __construct(AccountProxyInterface $current_user, MessengerInterface $messenger, LoggerChannelFactoryInterface $logger_factory, UserManager $user_manager, SocialAuthDataHandler $data_handler, ConfigFactoryInterface $config_factory, RouteProviderInterface $route_provider, EventDispatcherInterface $event_dispatcher) {
parent::__construct($current_user, $messenger, $logger_factory, $user_manager, $data_handler);
$this->configFactory = $config_factory;
$this->routeProvider = $route_provider;
$this->eventDispatcher = $event_dispatcher;
}