Matthias Andreas Benkard | 7b2a3a1 | 2021-08-16 10:57:25 +0200 | [diff] [blame^] | 1 | <?php |
| 2 | |
| 3 | namespace Adldap\Auth; |
| 4 | |
| 5 | use Adldap\AdldapException; |
| 6 | use Adldap\Connections\DetailedError; |
| 7 | |
| 8 | /** |
| 9 | * Class BindException. |
| 10 | * |
| 11 | * Thrown when binding to an LDAP connection fails. |
| 12 | */ |
| 13 | class BindException extends AdldapException |
| 14 | { |
| 15 | /** |
| 16 | * The detailed LDAP error. |
| 17 | * |
| 18 | * @var DetailedError |
| 19 | */ |
| 20 | protected $detailedError; |
| 21 | |
| 22 | /** |
| 23 | * Sets the detailed error. |
| 24 | * |
| 25 | * @param DetailedError|null $error |
| 26 | * |
| 27 | * @return $this |
| 28 | */ |
| 29 | public function setDetailedError(DetailedError $error = null) |
| 30 | { |
| 31 | $this->detailedError = $error; |
| 32 | |
| 33 | return $this; |
| 34 | } |
| 35 | |
| 36 | /** |
| 37 | * Returns the detailed error. |
| 38 | * |
| 39 | * @return DetailedError|null |
| 40 | */ |
| 41 | public function getDetailedError() |
| 42 | { |
| 43 | return $this->detailedError; |
| 44 | } |
| 45 | } |