improve exceptions
This commit is contained in:
@ -19,7 +19,7 @@ namespace D3\KlicktippPhpClient\Exceptions;
|
||||
|
||||
use Exception;
|
||||
|
||||
class BaseException extends Exception
|
||||
class BaseException extends Exception implements KlicktippExceptionInterface
|
||||
{
|
||||
public function __construct($message = "", $code = 0, Exception $previous = null)
|
||||
{
|
||||
|
24
src/Exceptions/InvalidCredentialTypeException.php
Normal file
24
src/Exceptions/InvalidCredentialTypeException.php
Normal file
@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Copyright (c) D3 Data Development (Inh. Thomas Dartsch)
|
||||
*
|
||||
* For the full copyright and license information, please view
|
||||
* the LICENSE file that was distributed with this source code.
|
||||
*
|
||||
* https://www.d3data.de
|
||||
*
|
||||
* @copyright (C) D3 Data Development (Inh. Thomas Dartsch)
|
||||
* @author D3 Data Development - Daniel Seifert <info@shopmodule.com>
|
||||
* @link https://www.oxidmodule.com
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace D3\KlicktippPhpClient\Exceptions;
|
||||
|
||||
use Assert\LazyAssertionException;
|
||||
|
||||
class InvalidCredentialTypeException extends LazyAssertionException implements KlicktippExceptionInterface
|
||||
{
|
||||
}
|
20
src/Exceptions/KlicktippExceptionInterface.php
Normal file
20
src/Exceptions/KlicktippExceptionInterface.php
Normal file
@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Copyright (c) D3 Data Development (Inh. Thomas Dartsch)
|
||||
*
|
||||
* For the full copyright and license information, please view
|
||||
* the LICENSE file that was distributed with this source code.
|
||||
*
|
||||
* https://www.d3data.de
|
||||
*
|
||||
* @copyright (C) D3 Data Development (Inh. Thomas Dartsch)
|
||||
* @author D3 Data Development - Daniel Seifert <info@shopmodule.com>
|
||||
* @link https://www.oxidmodule.com
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace D3\KlicktippPhpClient\Exceptions;
|
||||
|
||||
interface KlicktippExceptionInterface {}
|
@ -17,6 +17,8 @@ declare(strict_types=1);
|
||||
|
||||
namespace D3\KlicktippPhpClient\Exceptions;
|
||||
|
||||
class NoCredentialsException extends BaseException
|
||||
use Assert\LazyAssertionException;
|
||||
|
||||
class NoCredentialsException extends LazyAssertionException implements KlicktippExceptionInterface
|
||||
{
|
||||
}
|
||||
|
Reference in New Issue
Block a user