1: | <?php declare(strict_types = 1); |
2: | |
3: | namespace PHPStan\PhpDoc\Tag; |
4: | |
5: | use PHPStan\Type\Type; |
6: | |
7: | /** |
8: | * @api |
9: | */ |
10: | final class MethodTag |
11: | { |
12: | |
13: | /** |
14: | * @param array<string, MethodTagParameter> $parameters |
15: | * @param array<string, TemplateTag> $templateTags |
16: | */ |
17: | public function __construct( |
18: | private Type $returnType, |
19: | private bool $isStatic, |
20: | private array $parameters, |
21: | private array $templateTags, |
22: | ) |
23: | { |
24: | } |
25: | |
26: | public function getReturnType(): Type |
27: | { |
28: | return $this->returnType; |
29: | } |
30: | |
31: | public function isStatic(): bool |
32: | { |
33: | return $this->isStatic; |
34: | } |
35: | |
36: | /** |
37: | * @return array<string, MethodTagParameter> |
38: | */ |
39: | public function getParameters(): array |
40: | { |
41: | return $this->parameters; |
42: | } |
43: | |
44: | /** |
45: | * @return array<string, TemplateTag> |
46: | */ |
47: | public function getTemplateTags(): array |
48: | { |
49: | return $this->templateTags; |
50: | } |
51: | |
52: | } |
53: |