@@ -107,10 +107,10 @@ Session Attributes
107
107
Returns true if the attribute exists.
108
108
109
109
:method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Session::replace `
110
- Sets multiple attributes at once: takes a keyed array and sets each key => value pair;
110
+ Sets multiple attributes at once: takes a keyed array and sets each key => value pair.
111
111
112
112
:method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Session::remove `
113
- Deletes an attribute by key;
113
+ Deletes an attribute by key.
114
114
115
115
:method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Session::clear `
116
116
Clear all attributes.
@@ -123,7 +123,7 @@ an array. A few methods exist for "Bag" management:
123
123
124
124
:method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Session::getBag `
125
125
Gets a :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface ` by
126
- bag name;
126
+ bag name.
127
127
128
128
:method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Session::getFlashBag `
129
129
Gets the :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface `.
@@ -132,6 +132,7 @@ an array. A few methods exist for "Bag" management:
132
132
Session Metadata
133
133
................
134
134
135
+
135
136
:method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Session::getMetadataBag `
136
137
Gets the :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Storage\\ MetadataBag `
137
138
which contains information about the session.
@@ -157,16 +158,16 @@ bag types if necessary.
157
158
:class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface ` has
158
159
the following API which is intended mainly for internal purposes:
159
160
160
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface::getStorageKey `:
161
- Returns the key which the bag will ultimately store its array under in ``$_SESSION ``.
162
- Generally this value can be left at its default and is for internal use.
161
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface::getStorageKey `
162
+ Returns the key which the bag will ultimately store its array under in ``$_SESSION ``.
163
+ Generally this value can be left at its default and is for internal use.
163
164
164
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface::initialize `:
165
- This is called internally by Symfony session storage classes to link bag data
166
- to the session.
165
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface::initialize `
166
+ This is called internally by Symfony session storage classes to link bag data
167
+ to the session.
167
168
168
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface::getName `:
169
- Returns the name of the session bag.
169
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionBagInterface::getName `
170
+ Returns the name of the session bag.
170
171
171
172
Attributes
172
173
~~~~~~~~~~
@@ -175,11 +176,11 @@ The purpose of the bags implementing the :class:`Symfony\\Component\\HttpFoundat
175
176
is to handle session attribute storage. This might include things like user ID,
176
177
and remember me login settings or other user based state information.
177
178
178
- * :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBag `
179
- This is the standard default implementation.
179
+ :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBag `
180
+ This is the standard default implementation.
180
181
181
- * :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ NamespacedAttributeBag `
182
- This implementation allows for attributes to be stored in a structured namespace.
182
+ :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ NamespacedAttributeBag `
183
+ This implementation allows for attributes to be stored in a structured namespace.
183
184
184
185
Any plain key-value storage system is limited in the extent to which
185
186
complex data can be stored since each key must be unique. You can achieve
@@ -210,29 +211,29 @@ This way you can easily access a key within the stored array directly and easily
210
211
:class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface `
211
212
has a simple API
212
213
213
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::set `:
214
- Sets an attribute by key;
214
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::set `
215
+ Sets an attribute by key.
215
216
216
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::get `:
217
- Gets an attribute by key;
217
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::get `
218
+ Gets an attribute by key.
218
219
219
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::all `:
220
- Gets all attributes as an array of key => value;
220
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::all `
221
+ Gets all attributes as an array of key => value.
221
222
222
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::has `:
223
- Returns true if the attribute exists;
223
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::has `
224
+ Returns true if the attribute exists.
224
225
225
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::keys `:
226
- Returns an array of stored attribute keys;
226
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::keys `
227
+ Returns an array of stored attribute keys.
227
228
228
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::replace `:
229
- Sets multiple attributes at once: takes a keyed array and sets each key => value pair.
229
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::replace `
230
+ Sets multiple attributes at once: takes a keyed array and sets each key => value pair.
230
231
231
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::remove `:
232
- Deletes an attribute by key;
232
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::remove `
233
+ Deletes an attribute by key.
233
234
234
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::clear `:
235
- Clear the bag;
235
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Attribute\\ AttributeBagInterface::clear `
236
+ Clear the bag.
236
237
237
238
Flash Messages
238
239
~~~~~~~~~~~~~~
@@ -246,49 +247,49 @@ updated page or an error page. Flash messages set in the previous page request
246
247
would be displayed immediately on the subsequent page load for that session.
247
248
This is however just one application for flash messages.
248
249
249
- * :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ AutoExpireFlashBag `
250
- In this implementation, messages set in one page-load will
251
- be available for display only on the next page load. These messages will auto
252
- expire regardless of if they are retrieved or not.
250
+ :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ AutoExpireFlashBag `
251
+ In this implementation, messages set in one page-load will
252
+ be available for display only on the next page load. These messages will auto
253
+ expire regardless of if they are retrieved or not.
253
254
254
- * :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBag `
255
- In this implementation, messages will remain in the session until
256
- they are explicitly retrieved or cleared. This makes it possible to use ESI
257
- caching.
255
+ :class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBag `
256
+ In this implementation, messages will remain in the session until
257
+ they are explicitly retrieved or cleared. This makes it possible to use ESI
258
+ caching.
258
259
259
260
:class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface `
260
261
has a simple API
261
262
262
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::add `:
263
- Adds a flash message to the stack of specified type;
263
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::add `
264
+ Adds a flash message to the stack of specified type.
264
265
265
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::set `:
266
- Sets flashes by type; This method conveniently takes both single messages as
267
- a ``string `` or multiple messages in an ``array ``.
266
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::set `
267
+ Sets flashes by type; This method conveniently takes both single messages as
268
+ a ``string `` or multiple messages in an ``array ``.
268
269
269
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::get `:
270
- Gets flashes by type and clears those flashes from the bag;
270
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::get `
271
+ Gets flashes by type and clears those flashes from the bag.
271
272
272
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::setAll `:
273
- Sets all flashes, accepts a keyed array of arrays ``type => array(messages) ``;
273
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::setAll `
274
+ Sets all flashes, accepts a keyed array of arrays ``type => array(messages) ``.
274
275
275
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::all `:
276
- Gets all flashes (as a keyed array of arrays) and clears the flashes from the bag;
276
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::all `
277
+ Gets all flashes (as a keyed array of arrays) and clears the flashes from the bag.
277
278
278
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::peek `:
279
- Gets flashes by type (read only);
279
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::peek `
280
+ Gets flashes by type (read only).
280
281
281
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::peekAll `:
282
- Gets all flashes (read only) as keyed array of arrays;
282
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::peekAll `
283
+ Gets all flashes (read only) as keyed array of arrays.
283
284
284
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::has `:
285
- Returns true if the type exists, false if not;
285
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::has `
286
+ Returns true if the type exists, false if not.
286
287
287
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::keys `:
288
- Returns an array of the stored flash types;
288
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::keys `
289
+ Returns an array of the stored flash types.
289
290
290
- * :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::clear `:
291
- Clears the bag;
291
+ :method: `Symfony\\ Component\\ HttpFoundation\\ Session\\ Flash\\ FlashBagInterface::clear `
292
+ Clears the bag.
292
293
293
294
For simple applications it is usually sufficient to have one flash message per
294
295
type, for example a confirmation notice after a form is submitted. However,
0 commit comments