/
jagepard
/
Rudra-Router
Обзор
Документация
Войти
/
jagepard
/
Rudra-Router
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
tests/Stub/Controllers/AnnotatedController.php
52 строки
1 KB
Jagepard
style: apply PSR-12 formatting to empty class body
03 июл 2026, 21:23
03 июл 2026, 21:23
b90c045
Код
Авторство
О чём код?
<?php declare(strict_types=1); namespace Rudra\Router\Tests\Stub\Controllers; use Rudra\Annotations\AfterMiddleware; use Rudra\Annotations\Middleware; use Rudra\Annotations\Routing; use Rudra\Container\Facades\Rudra; class AnnotatedController { #[Routing(url: "annotated/index", method: "GET")] #[Middleware(name: "AuthMiddleware", params: ["admin"])] public function actionIndex(): void { Rudra::config()->set(["annotatedIndex" => "annotatedIndex"]); } #[Routing(url: "annotated/edit/:id", method: "POST")] #[Middleware(name: "AuthMiddleware")] #[AfterMiddleware(name: "LogMiddleware", params: ["edit"])] public function actionEdit(string $id): void { Rudra::config()->set(["annotatedEdit" => "annotatedEdit"]); } #[Routing(url: "annotated/view/:id", method: "GET")] public function actionView(string $id): void { Rudra::config()->set(["annotatedView" => "annotatedView"]); } public function shipInit() { } public function containerInit() { } public function init() { } public function before() { } public function after() { } }