AddressEncoderException.php 721 B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. /*
  3. * This file is part of SwiftMailer.
  4. * (c) 2018 Christian Schmidt
  5. *
  6. * For the full copyright and license information, please view the LICENSE
  7. * file that was distributed with this source code.
  8. */
  9. /**
  10. * AddressEncoderException when the specified email address is in a format that
  11. * cannot be encoded by a given address encoder.
  12. *
  13. * @author Christian Schmidt
  14. */
  15. class Swift_AddressEncoderException extends Swift_RfcComplianceException
  16. {
  17. protected $address;
  18. public function __construct(string $message, string $address)
  19. {
  20. parent::__construct($message);
  21. $this->address = $address;
  22. }
  23. public function getAddress(): string
  24. {
  25. return $this->address;
  26. }
  27. }