ICanBoogie/Routing master
  • Namespace
  • Class

Namespaces

  • ICanBoogie
    • Routing
      • Controller
      • Route
      • RouteDispatcher

Classes

  • RescueEvent

Class RescueEvent

Event class for the ICanBoogie\Routing\RouteDispatcher::rescue event.

Event hooks may use this event to rescue a route by providing a suitable response, or replace the exception to throw if the rescue fails.

ICanBoogie\Event
Extended by ICanBoogie\Routing\Route\RescueEvent
Namespace: ICanBoogie\Routing\Route
Located at Route/RescueEvent.php

Methods summary

protected Exception
# get_exception( )

Returns

Exception
protected Exception
# set_exception( Exception $exception )

Parameters

$exception

Returns

Exception
protected ICanBoogie\HTTP\Request
# get_request( )

Returns

ICanBoogie\HTTP\Request
protected ICanBoogie\HTTP\Response|null
# get_response( )

Returns

ICanBoogie\HTTP\Response|null
protected
# set_response( ICanBoogie\HTTP\Response $response = null )

Parameters

$response
public
# __construct( ICanBoogie\Routing\Route $target, Exception & $exception, ICanBoogie\HTTP\Request $request, ICanBoogie\HTTP\Response & $response = null )

The event is constructed with the type self::TYPE.

The event is constructed with the type self::TYPE.

Parameters

$target
$exception
Reference to the exception thrown while dispatching the route.
$request
$response

Constants summary

string TYPE
# 'rescue'

Properties summary

Magic properties

public Exception $exception
public ICanBoogie\HTTP\Response|null $response
public read-only ICanBoogie\HTTP\Request $request
ICanBoogie/Routing master API documentation generated by ApiGen