| @@ 53-72 (lines=20) @@ | ||
| 50 | ); |
|
| 51 | } |
|
| 52 | ||
| 53 | public function init() |
|
| 54 | { |
|
| 55 | $this->router = new Router(); |
|
| 56 | $collection = $this->router->getRoutes(); |
|
| 57 | ||
| 58 | for ($i = 0; $i < 1000; ++$i) { |
|
| 59 | RouteFactory::generateLiteralRoute( |
|
| 60 | $collection, |
|
| 61 | "index." . $i, |
|
| 62 | Route::class, |
|
| 63 | "", |
|
| 64 | "/index" . $i); |
|
| 65 | ||
| 66 | RouteFactory::generateStandardRoute( |
|
| 67 | $collection, |
|
| 68 | "index.standard" . $i, |
|
| 69 | StandardRoute::class, |
|
| 70 | "/" . $i); |
|
| 71 | } |
|
| 72 | } |
|
| 73 | } |
|
| @@ 46-65 (lines=20) @@ | ||
| 43 | $this->router->matchRequest($request); |
|
| 44 | } |
|
| 45 | ||
| 46 | public function init() |
|
| 47 | { |
|
| 48 | $this->router = new Router(); |
|
| 49 | $collection = $this->router->getRoutes(); |
|
| 50 | ||
| 51 | for ($i = 0; $i < 1000; ++$i) { |
|
| 52 | RouteFactory::generateLiteralRoute( |
|
| 53 | $collection, |
|
| 54 | "index." . $i, |
|
| 55 | Route::class, |
|
| 56 | "", |
|
| 57 | "/index" . $i); |
|
| 58 | ||
| 59 | RouteFactory::generateStandardRoute( |
|
| 60 | $collection, |
|
| 61 | "index.standard" . $i, |
|
| 62 | StandardRoute::class, |
|
| 63 | "/".$i); |
|
| 64 | } |
|
| 65 | } |
|
| 66 | } |
|