Start project PHP Back.

50% routes.
This commit is contained in:
2026-03-20 11:40:11 +01:00
parent fedbf51c91
commit c36b95a15f
13 changed files with 555 additions and 1 deletions

31
src/Http/Route.php Normal file
View File

@@ -0,0 +1,31 @@
<?php
namespace App\Http;
/**
* Permet de définir une route précise.
*/
final class Route {
public private(set) string $routeUrl;
public private(set) string $routeName;
public private(set) string $routeController;
public private(set) string $routeAction;
public private(set) array $routeMethods;
public function __construct(
string $routeUrl,
string $routeName,
string $routeController,
string $routeAction,
array $routeMethods
){
$this->routeUrl = $routeUrl;
$this->routeName = $routeName;
$this->routeController = $routeController;
$this->routeAction = $routeAction;
$this->routeMethods = $routeMethods;
}
}