Skip to content

Commit 97bf9bb

Browse files
wouterjnicolas-grekas
authored andcommitted
[HttpFoundation][HttpKernel] Add missing void PHPdoc return types
1 parent 0bb5ab0 commit 97bf9bb

File tree

5 files changed

+37
-0
lines changed

5 files changed

+37
-0
lines changed

Session/Attribute/AttributeBagInterface.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ public function get(string $name, mixed $default = null): mixed;
3232

3333
/**
3434
* Sets an attribute.
35+
*
36+
* @return void
3537
*/
3638
public function set(string $name, mixed $value);
3739

@@ -42,6 +44,9 @@ public function set(string $name, mixed $value);
4244
*/
4345
public function all(): array;
4446

47+
/**
48+
* @return void
49+
*/
4550
public function replace(array $attributes);
4651

4752
/**

Session/Flash/FlashBagInterface.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,15 @@ interface FlashBagInterface extends SessionBagInterface
2222
{
2323
/**
2424
* Adds a flash message for the given type.
25+
*
26+
* @return void
2527
*/
2628
public function add(string $type, mixed $message);
2729

2830
/**
2931
* Registers one or more messages for a given type.
32+
*
33+
* @return void
3034
*/
3135
public function set(string $type, string|array $messages);
3236

@@ -57,6 +61,8 @@ public function all(): array;
5761

5862
/**
5963
* Sets all flash messages.
64+
*
65+
* @return void
6066
*/
6167
public function setAll(array $messages);
6268

Session/SessionBagInterface.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ public function getName(): string;
2525

2626
/**
2727
* Initializes the Bag.
28+
*
29+
* @return void
2830
*/
2931
public function initialize(array &$array);
3032

Session/SessionInterface.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ public function getId(): string;
3434

3535
/**
3636
* Sets the session ID.
37+
*
38+
* @return void
3739
*/
3840
public function setId(string $id);
3941

@@ -44,6 +46,8 @@ public function getName(): string;
4446

4547
/**
4648
* Sets the session name.
49+
*
50+
* @return void
4751
*/
4852
public function setName(string $name);
4953

@@ -78,6 +82,8 @@ public function migrate(bool $destroy = false, int $lifetime = null): bool;
7882
* This method is generally not required for real sessions as
7983
* the session will be automatically saved at the end of
8084
* code execution.
85+
*
86+
* @return void
8187
*/
8288
public function save();
8389

@@ -93,6 +99,8 @@ public function get(string $name, mixed $default = null): mixed;
9399

94100
/**
95101
* Sets an attribute.
102+
*
103+
* @return void
96104
*/
97105
public function set(string $name, mixed $value);
98106

@@ -103,6 +111,8 @@ public function all(): array;
103111

104112
/**
105113
* Sets attributes.
114+
*
115+
* @return void
106116
*/
107117
public function replace(array $attributes);
108118

@@ -115,6 +125,8 @@ public function remove(string $name): mixed;
115125

116126
/**
117127
* Clears all attributes.
128+
*
129+
* @return void
118130
*/
119131
public function clear();
120132

@@ -125,6 +137,8 @@ public function isStarted(): bool;
125137

126138
/**
127139
* Registers a SessionBagInterface with the session.
140+
*
141+
* @return void
128142
*/
129143
public function registerBag(SessionBagInterface $bag);
130144

Session/Storage/SessionStorageInterface.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ public function getId(): string;
4040

4141
/**
4242
* Sets the session ID.
43+
*
44+
* @return void
4345
*/
4446
public function setId(string $id);
4547

@@ -50,6 +52,8 @@ public function getName(): string;
5052

5153
/**
5254
* Sets the session name.
55+
*
56+
* @return void
5357
*/
5458
public function setName(string $name);
5559

@@ -90,13 +94,17 @@ public function regenerate(bool $destroy = false, int $lifetime = null): bool;
9094
* a real PHP session would interfere with testing, in which case
9195
* it should actually persist the session data if required.
9296
*
97+
* @return void
98+
*
9399
* @throws \RuntimeException if the session is saved without being started, or if the session
94100
* is already closed
95101
*/
96102
public function save();
97103

98104
/**
99105
* Clear all session data in memory.
106+
*
107+
* @return void
100108
*/
101109
public function clear();
102110

@@ -109,6 +117,8 @@ public function getBag(string $name): SessionBagInterface;
109117

110118
/**
111119
* Registers a SessionBagInterface for use.
120+
*
121+
* @return void
112122
*/
113123
public function registerBag(SessionBagInterface $bag);
114124

0 commit comments

Comments
 (0)