diff options
Diffstat (limited to 'Core/Exception/AuthenticationException.php')
-rw-r--r-- | Core/Exception/AuthenticationException.php | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/Core/Exception/AuthenticationException.php b/Core/Exception/AuthenticationException.php index a43b998..f788a5d 100644 --- a/Core/Exception/AuthenticationException.php +++ b/Core/Exception/AuthenticationException.php @@ -16,7 +16,7 @@ namespace Symfony\Component\Security\Core\Exception; * * @author Fabien Potencier <fabien.potencier@symfony-project.com> */ -class AuthenticationException extends \RuntimeException +class AuthenticationException extends \RuntimeException implements \Serializable { protected $extraInformation; @@ -36,4 +36,26 @@ class AuthenticationException extends \RuntimeException { $this->extraInformation = $extraInformation; } + + public function serialize() + { + return serialize(array( + $this->extraInformation, + $this->code, + $this->message, + $this->file, + $this->line, + )); + } + + public function unserialize($str) + { + list( + $this->extraInformation, + $this->code, + $this->message, + $this->file, + $this->line + ) = unserialize($str); + } } |