Class AutoExpireFlashBag
AutoExpireFlashBag flash message container.
-
Symfony\Component\HttpFoundation\Session\Flash\AutoExpireFlashBag
implements
Symfony\Component\HttpFoundation\Session\Flash\FlashBagInterface
Methods summary
public
|
#
__construct( string $storageKey = '_sf2_flashes' )
Constructor.
Parameters
- $storageKey
- The key used to store flashes in the session.
|
public
string
|
#
getName( )
Gets this bag's name.
Returns
string
Implementation of
|
public
|
|
public
|
#
initialize( array & $flashes )
Initializes the Bag.
Parameters
Implementation of
|
public
|
#
add( string $type, string $message )
Adds a flash message for type.
Adds a flash message for type.
Parameters
Implementation of
|
public
array
|
#
peek( string $type, array $default = array() )
Gets flash messages for a given type.
Gets flash messages for a given type.
Parameters
- $type
- Message category type.
- $default
- Default value if $type does not exist.
Returns
array
Implementation of
|
public
array
|
#
peekAll( )
Gets all flash messages.
Returns
array
Implementation of
|
public
array
|
#
get( string $type, array $default = array() )
Gets and clears flash from the stack.
Gets and clears flash from the stack.
Parameters
- $type
- $default
- Default value if $type does not exist.
Returns
array
Implementation of
|
public
array
|
#
all( )
Gets and clears flashes from the stack.
Gets and clears flashes from the stack.
Returns
array
Implementation of
|
public
|
#
setAll( array $messages )
Sets all flash messages.
Implementation of
|
public
|
#
set( string $type, string|array $messages )
Registers a message for a given type.
Registers a message for a given type.
Parameters
Implementation of
|
public
boolean
|
#
has( string $type )
Has flash messages for a given type?
Has flash messages for a given type?
Parameters
Returns
boolean
Implementation of
|
public
array
|
#
keys( )
Returns a list of all defined types.
Returns a list of all defined types.
Returns
array
Implementation of
|
public
string
|
#
getStorageKey( )
Gets the storage key for this bag.
Gets the storage key for this bag.
Returns
string
Implementation of
|
public
mixed
|
#
clear( )
Clears out data from bag.
Clears out data from bag.
Returns
mixed Whatever data was contained.
Implementation of
|