PHP Class CapMousse\ReactRestify\Routing\Route

Inheritance: extends CapMousse\ReactRestify\Evenement\EventEmitter
Afficher le fichier Open project: capmousse/react-restify

Méthodes publiques

Свойство Type Description
$action Callable Route action
$method String Route method type
$parsedRoute String Regexp ready route

Méthodes publiques

Méthode Description
__construct ( String $method, String $uri, Callable $action )
after ( Callable $callback ) : Void Helper to listing to after event
isParsed ( ) : boolean Check if uri is parsed
parse ( ) : void Parse route uri
run ( Request $request, CapMousse\ReactRestify\Http\Response $response, Callable $next ) : Void Run the current route
where ( String $param, String $filter ) : void Create a new filter for current route

Method Details

__construct() public méthode

public __construct ( String $method, String $uri, Callable $action )
$method String
$uri String
$action Callable

after() public méthode

Helper to listing to after event
public after ( Callable $callback ) : Void
$callback Callable
Résultat Void

isParsed() public méthode

Check if uri is parsed
public isParsed ( ) : boolean
Résultat boolean

parse() public méthode

Parse route uri
public parse ( ) : void
Résultat void

run() public méthode

Run the current route
public run ( Request $request, CapMousse\ReactRestify\Http\Response $response, Callable $next ) : Void
$request CapMousse\ReactRestify\Http\Request
$response CapMousse\ReactRestify\Http\Response
$next Callable
Résultat Void

where() public méthode

Create a new filter for current route
public where ( String $param, String $filter ) : void
$param String parameter to filter
$filter String regexp to execute
Résultat void

Property Details

$action public_oe property

Route action
public Callable $action
Résultat Callable

$method public_oe property

Route method type
public String $method
Résultat String

$parsedRoute public_oe property

Regexp ready route
public String $parsedRoute
Résultat String