/**
  * @param Payone_SessionStatus_Request_Interface $request
  * @return bool
  * @throws Payone_SessionStatus_Exception_MissmatchingKeys
  */
 public function validateRequest(Payone_SessionStatus_Request_Interface $request)
 {
     if ($request->getKey() !== $this->getKey()) {
         throw new Payone_SessionStatus_Exception_MissmatchingKeys();
     }
     return true;
 }
 /**
  * @param Exception $e
  * @param null|Payone_SessionStatus_Request_Interface $request
  */
 public function protocolException(Exception $e, Payone_SessionStatus_Request_Interface $request = null)
 {
     if ($request !== null) {
         $this->getServiceApplyFilters()->apply($request->toArray());
     }
     foreach ($this->loggers as $key => $logger) {
         /** @var $logger Payone_Protocol_Logger_Interface */
         $logger->log(get_class($e) . ' ' . $e->getMessage());
         if ($request !== null) {
             $requestAsString = $request->__toString();
             $logger->log($requestAsString, Payone_Protocol_Logger_Interface::LEVEL_ERROR);
         }
     }
 }