Skip to content

Commit

Permalink
exception: use natural explanatory style
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Dec 12, 2024
1 parent 4a49c1d commit 97be91a
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/Application/exceptions.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,37 +13,38 @@


/**
* The exception that is thrown when user attempts to terminate the current presenter or application.
* This is special "silent exception" with no error message or code.
* A silent exception used to terminate the current presenter or application.
* Contains no error message or code.
*/
class AbortException extends \LogicException
{
}


/** @internal */
final class SwitchException extends AbortException
{
}


/**
* Application fatal error.
* Fatal error in the application.
*/
class ApplicationException extends \Exception
{
}


/**
* The exception that is thrown when a presenter cannot be loaded.
* The requested presenter cannot be loaded.
*/
class InvalidPresenterException extends \Exception
{
}


/**
* The exception that indicates client error with HTTP code 4xx.
* The request resulted in HTTP 4xx client error.
*/
class BadRequestException extends \LogicException
{
Expand All @@ -65,7 +66,7 @@ public function getHttpCode(): int


/**
* Forbidden request exception - access denied.
* Access to the requested resource is forbidden.
*/
class ForbiddenRequestException extends BadRequestException
{
Expand Down

0 comments on commit 97be91a

Please sign in to comment.