1 | <?php |
||
23 | class Action implements ActionInterface |
||
24 | { |
||
25 | /** |
||
26 | * @var string |
||
27 | */ |
||
28 | private $name; |
||
29 | |||
30 | /** |
||
31 | * @var HrefInterface |
||
32 | */ |
||
33 | private $href; |
||
34 | |||
35 | /** |
||
36 | * @var Method |
||
37 | */ |
||
38 | private $method; |
||
39 | |||
40 | /** |
||
41 | * @var array |
||
42 | */ |
||
43 | private $attributes; |
||
44 | |||
45 | /** |
||
46 | * Constructor. |
||
47 | * |
||
48 | * @param string $name |
||
49 | * @param HrefInterface $href |
||
50 | * @param Method $method |
||
51 | * @param array $attributes |
||
52 | */ |
||
53 | 6 | public function __construct(string $name, HrefInterface $href, Method $method, array $attributes = []) |
|
60 | |||
61 | /** |
||
62 | * {@inheritdoc} |
||
63 | */ |
||
64 | 2 | public function getName(): string |
|
68 | |||
69 | /** |
||
70 | * {@inheritdoc} |
||
71 | */ |
||
72 | 3 | public function getHref(): HrefInterface |
|
76 | |||
77 | /** |
||
78 | * {@inheritdoc} |
||
79 | */ |
||
80 | 1 | public function setHref(HrefInterface $href): void |
|
84 | |||
85 | /** |
||
86 | * {@inheritdoc} |
||
87 | */ |
||
88 | 2 | public function getMethod(): Method |
|
92 | |||
93 | /** |
||
94 | * {@inheritdoc} |
||
95 | */ |
||
96 | 1 | public function setMethod(Method $method): void |
|
100 | |||
101 | /** |
||
102 | * {@inheritdoc} |
||
103 | */ |
||
104 | 3 | public function getAttributes(): array |
|
108 | |||
109 | /** |
||
110 | * {@inheritdoc} |
||
111 | */ |
||
112 | 1 | public function setAttributes(array $attributes): void |
|
116 | } |
||
117 |