This library offers some ready to use PHP Exceptions.
ArrayCaseClassName |
Parameter |
Usage |
|---|---|---|
ClassInvalidException |
string $classstring $expected |
Used to indicate that a given or passed class is invalid. |
ConfigurationName |
Parameter |
Usage |
|---|---|---|
ConfigurationMissingException |
string $hint |
Used to indicate that a configuration or an action is missing. |
DbName |
Parameter |
Usage |
|---|---|---|
DbEntityNotFoundException |
string $class |
Used to indicate that a db entity was not found. |
FileFunctionParserName |
Parameter |
Usage |
|---|---|---|
ParserException |
string $parseStringstring $context |
Used to indicate that a given string could not be parsed. |
TypeName |
Parameter |
Usage |
|---|---|---|
TypeInvalidException |
string $expected?string $given = null |
Used to indicate that a given or passed variable is the wrong type. |
composer require ixnode/php-exceptionvendor/bin/php-exception -Vphp-exception 0.1.0 (12-30-2022 11:41:25) - Björn Hempel <bjoern@hempel.li>use Ixnode\PhpException\FileNotFoundException;throw new FileNotFoundException('path-to-file');git clone git@github.com:ixnode/php-exception.git && cd php-exceptioncomposer installcomposer testThis tool is licensed under the MIT License - see the LICENSE file for details