1 | <?php declare(strict_types = 1); |
||
15 | class Meta |
||
16 | { |
||
17 | const NAME = 'php-api.attribute'; |
||
18 | |||
19 | /** |
||
20 | * @var Description |
||
21 | */ |
||
22 | private $description; |
||
23 | |||
24 | /** |
||
25 | * @var Operation |
||
26 | */ |
||
27 | private $operation; |
||
28 | |||
29 | /** |
||
30 | * @var Path |
||
31 | */ |
||
32 | private $path; |
||
33 | |||
34 | /** |
||
35 | * @param Description $description |
||
36 | * @param Operation $operation |
||
37 | * @param Path $path |
||
38 | */ |
||
39 | public function __construct(Description $description, Operation $operation, Path $path) |
||
45 | |||
46 | /** |
||
47 | * @param ServerRequestInterface $request |
||
48 | * @return Meta |
||
49 | */ |
||
50 | public static function getFromRequest(ServerRequestInterface $request): Meta |
||
54 | |||
55 | /** |
||
56 | * @param ServerRequestInterface $request |
||
57 | * @param Description $description |
||
58 | * @param Operation $operation |
||
59 | * @param Path $path |
||
60 | * @return ServerRequestInterface |
||
61 | */ |
||
62 | public static function requestWith( |
||
71 | |||
72 | /** |
||
73 | * @return Description |
||
74 | */ |
||
75 | public function getDescription(): Description |
||
79 | |||
80 | /** |
||
81 | * @return Operation |
||
82 | */ |
||
83 | public function getOperation(): Operation |
||
87 | |||
88 | /** |
||
89 | * @return Path |
||
90 | */ |
||
91 | public function getPath(): Path |
||
95 | } |