EncryptedStore (Session)
EncryptedStore
class EncryptedStore extends Store (View source)
Methods
void | __construct( string $name, SessionHandlerInterface $handler, Encrypter $encrypter, string|null $id = null) Create a new session instance. | |
start() | from Store | |
getId() | from Store | |
setId($id) | from Store | |
bool | isValidId( string $id) Determine if this is a valid session ID. | from Store |
getName() | from Store | |
setName($name) | from Store | |
invalidate($lifetime = null) | from Store | |
migrate($destroy = false, $lifetime = null) | from Store | |
bool | regenerate( bool $destroy = false) Generate a new session identifier. | from Store |
save() | from Store | |
void | ageFlashData() Age the flash data for the session. | from Store |
has($name) | from Store | |
get($name, $default = null) | from Store | |
mixed | pull( string $key, string $default = null) Get the value of a given key and then forget it. | from Store |
bool | hasOldInput( string $key = null) Determine if the session contains old input. | from Store |
mixed | getOldInput( string $key = null, mixed $default = null) Get the requested item from the flashed input array. | from Store |
set($name, $value) | from Store | |
void | put( string|array $key, mixed $value = null) Put a key / value pair or array of key / value pairs in the session. | from Store |
void | push( string $key, mixed $value) Push a value onto a session array. | from Store |
void | flash( string $key, mixed $value) Flash a key / value pair to the session. | from Store |
void | now( string $key, mixed $value) Flash a key / value pair to the session for immediate use. | from Store |
void | flashInput( array $value) Flash an input array to the session. | from Store |
void | reflash() Reflash all of the session flash data. | from Store |
void | keep( array|mixed $keys = null) Reflash a subset of the current flash data. | from Store |
all() | from Store | |
replace( array $attributes) | from Store | |
remove($name) | from Store | |
void | forget( string|array $keys) Remove one or many items from the session. | from Store |
clear() | from Store | |
void | flush() Remove all of the items from the session. | from Store |
isStarted() | from Store | |
registerBag( SessionBagInterface $bag) | from Store | |
getBag($name) | from Store | |
getMetadataBag() | from Store | |
array | getBagData( string $name) Get the raw bag data array for a given bag. | from Store |
string | token() Get the CSRF token value. | from Store |
string | getToken() Get the CSRF token value. | from Store |
void | regenerateToken() Regenerate the CSRF token value. | from Store |
string|null | previousUrl() Get the previous URL from the session. | from Store |
void | setPreviousUrl( string $url) Set the "previous" URL in the session. | from Store |
void | setExists( bool $value) Set the existence of the session on the handler if applicable. | from Store |
SessionHandlerInterface | getHandler() Get the underlying session handler implementation. | from Store |
bool | handlerNeedsRequest() Determine if the session handler needs a request. | from Store |
void | setRequestOnHandler( Request $request) Set the request on the handler instance. | from Store |
Encrypter | getEncrypter() Get the encrypter instance. |
Details
void __construct( string $name, SessionHandlerInterface $handler, Encrypter $encrypter, string|null $id = null)
Create a new session instance.
start()
getId()
setId($id)
bool isValidId( string $id)
Determine if this is a valid session ID.
getName()
setName($name)
invalidate($lifetime = null)
migrate($destroy = false, $lifetime = null)
bool regenerate( bool $destroy = false)
Generate a new session identifier.
save()
void ageFlashData()
Age the flash data for the session.
has($name)
get($name, $default = null)
mixed pull( string $key, string $default = null)
Get the value of a given key and then forget it.
bool hasOldInput( string $key = null)
Determine if the session contains old input.
mixed getOldInput( string $key = null, mixed $default = null)
Get the requested item from the flashed input array.
set($name, $value)
void put( string|array $key, mixed $value = null)
Put a key / value pair or array of key / value pairs in the session.
void push( string $key, mixed $value)
Push a value onto a session array.
void flash( string $key, mixed $value)
Flash a key / value pair to the session.
void now( string $key, mixed $value)
Flash a key / value pair to the session for immediate use.
void flashInput( array $value)
Flash an input array to the session.
void reflash()
Reflash all of the session flash data.
void keep( array|mixed $keys = null)
Reflash a subset of the current flash data.
all()
replace( array $attributes)
remove($name)
void forget( string|array $keys)
Remove one or many items from the session.
clear()
void flush()
Remove all of the items from the session.
isStarted()
registerBag( SessionBagInterface $bag)
getBag($name)
getMetadataBag()
array getBagData( string $name)
Get the raw bag data array for a given bag.
string token()
Get the CSRF token value.
string getToken()
Get the CSRF token value.
void regenerateToken()
Regenerate the CSRF token value.
string|null previousUrl()
Get the previous URL from the session.
void setPreviousUrl( string $url)
Set the "previous" URL in the session.
void setExists( bool $value)
Set the existence of the session on the handler if applicable.
SessionHandlerInterface getHandler()
Get the underlying session handler implementation.
bool handlerNeedsRequest()
Determine if the session handler needs a request.
void setRequestOnHandler( Request $request)
Set the request on the handler instance.
Encrypter getEncrypter()
Get the encrypter instance.
© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/5.1/Illuminate/Session/EncryptedStore.html