Route class
Framework\Routing\Attributes\Route
Class Route.
Defined in libraries/routing/src/Attributes/Route.php
Properties #
- $methods
- -
- $path
- -
- $arguments
- -
- $name
- -
- $origins
- -
$methods
protected array $methods
$path
protected string $path
$arguments
protected string $arguments
$name
protected ?string $name
$origins
protected array $origins
Methods #
- __construct()
- Route constructor.
- getArguments()
- -
- getMethods()
- -
- getName()
- -
- getOrigins()
- -
- getPath()
- -
__construct()
public function __construct(array|string $methods, string $path, string $arguments = '*', ?string $name = NULL, array|string $origins = array (
))
Route constructor.
Parameters
- array|string $methods - The Route HTTP Methods
- string $path - The Route path
- string $arguments - The Route action arguments
- ?string $name - The Route name
- array|string $origins - The Route origins
getArguments()
public function getArguments(): string
Returns
string
getMethods()
public function getMethods(): array
Returns
array
getName()
public function getName(): ?string
Returns
?string
getOrigins()
public function getOrigins(): array
Returns
array
getPath()
public function getPath(): string
Returns
string