/**
  * Implements chain of responsibility logic, if current handler could
  * manage the current message then do it, if not, then pass msg to next sibling
  * @param OpenIdMessage $message
  * @return mixed
  * @throws InvalidOpenIdMessageException
  */
 public function handleMessage(OpenIdMessage $message)
 {
     if ($this->canHandle($message)) {
         //handle request
         return $this->internalHandle($message);
     } else {
         if (isset($this->successor) && !is_null($this->successor)) {
             return $this->successor->handleMessage($message);
         }
     }
     $this->log_service->warning_msg(sprintf(OpenIdErrorMessages::UnhandledMessage, $message->toString()));
     $ex = new InvalidOpenIdMessageException(sprintf(OpenIdErrorMessages::UnhandledMessage, $message->toString()));
     $this->checkpoint_service->trackException($ex);
     throw $ex;
 }
 /**
  * @param IAssociationService               $association_service
  * @param INonceService                     $nonce_service
  * @param ILogService                       $log_service
  * @param ICheckPointService                $checkpoint_service
  * @param IServerConfigurationService       $configuration_service
  * @param IOpenIdServerConfigurationService $openid_configuration_service
  * @param                                   $successor
  */
 public function __construct(IAssociationService $association_service, INonceService $nonce_service, ILogService $log_service, ICheckPointService $checkpoint_service, IServerConfigurationService $configuration_service, IOpenIdServerConfigurationService $openid_configuration_service, $successor)
 {
     parent::__construct($successor, $log_service, $checkpoint_service);
     $this->association_service = $association_service;
     $this->nonce_service = $nonce_service;
     $this->configuration_service = $configuration_service;
     $this->openid_configuration_service = $openid_configuration_service;
 }
 public function __construct(IAuthService $authService, IMementoOpenIdRequestService $memento_service, IOpenIdAuthenticationStrategy $auth_strategy, IServerExtensionsService $server_extensions_service, IAssociationService $association_service, ITrustedSitesService $trusted_sites_service, IServerConfigurationService $server_configuration_service, INonceService $nonce_service, ILogService $log, ICheckPointService $checkpoint_service, $successor)
 {
     parent::__construct($successor, $log, $checkpoint_service);
     $this->auth_service = $authService;
     $this->memento_service = $memento_service;
     $this->auth_strategy = $auth_strategy;
     $this->server_extensions_service = $server_extensions_service;
     $this->association_service = $association_service;
     $this->trusted_sites_service = $trusted_sites_service;
     $this->server_configuration_service = $server_configuration_service;
     $this->extensions = $this->server_extensions_service->getAllActiveExtensions();
     $this->nonce_service = $nonce_service;
 }
 public function __construct(ILogService $log, ICheckPointService $checkpoint_service, $successor)
 {
     parent::__construct($successor, $log, $checkpoint_service);
 }