classe Session implémente CollectionInterface (Voir la source)

Constantes

CORE_SESSION_KEY

The internal session variable

Méthodes

static mixed
configure(array $config)

Configure session instance

static mixed
getInstance()

Get session singleton

bool
start()

Session starter.

regenerate()

Generate session

bool
has(string $key, bool $strict = false)

Allows checking for the existence of a key in the session collection

bool
exists(string $key)

Allows checking for the existence of a key in the session collection

bool
isEmpty()

Check whether a collection is empty.

mixed
get(string $key, mixed $default = null)

Retrieves a value or value collection.

add(string $key, mixed $value, bool $next = false)

Add an entry to the collection

put($key, $value, $next = false)

The add alias

array
all()

Returns the list of session variables

remove(string $key)

Delete an entry in the collection

set(string $key, mixed $value)

set

mixed
flash(mixed $key, mixed $message = null)

Add flash data After the data recovery is automatic deleted

array
toArray()

Returns the list of session data as a array.

clearFash()

Empty the flash system.

clear()

Allows to clear the cache except csrf and __bow.flash

flush()

Allows you to empty the session

array
toObject()

Returns the list of session data as a toObject.

string
__toString()

__toString

Détails

static mixed configure(array $config)

Configure session instance

Paramètres

array $config

Valeur de retour

mixed

static mixed getInstance()

Get session singleton

Valeur de retour

mixed

bool start()

Session starter.

Valeur de retour

bool

regenerate()

Generate session

bool has(string $key, bool $strict = false)

Allows checking for the existence of a key in the session collection

Paramètres

string $key
bool $strict

Valeur de retour

bool

bool exists(string $key)

Allows checking for the existence of a key in the session collection

Paramètres

string $key

Valeur de retour

bool

bool isEmpty()

Check whether a collection is empty.

Valeur de retour

bool

mixed get(string $key, mixed $default = null)

Retrieves a value or value collection.

Paramètres

string $key
mixed $default

Valeur de retour

mixed

CollectionInterface add(string $key, mixed $value, bool $next = false)

Add an entry to the collection

Paramètres

string $key
mixed $value
bool $next

Valeur de retour

CollectionInterface

Exceptions

InvalidArgumentException

put($key, $value, $next = false)

The add alias

Paramètres

$key
$value
$next

Voir aussi

Session::add

array all()

Returns the list of session variables

Valeur de retour

array

CollectionInterface remove(string $key)

Delete an entry in the collection

Paramètres

string $key

Valeur de retour

CollectionInterface

CollectionInterface set(string $key, mixed $value)

set

Paramètres

string $key
mixed $value

Valeur de retour

CollectionInterface

mixed flash(mixed $key, mixed $message = null)

Add flash data After the data recovery is automatic deleted

Paramètres

mixed $key
mixed $message

Valeur de retour

mixed

array toArray()

Returns the list of session data as a array.

Valeur de retour

array

clearFash()

Empty the flash system.

clear()

Allows to clear the cache except csrf and __bow.flash

flush()

Allows you to empty the session

array toObject()

Returns the list of session data as a toObject.

Valeur de retour

array

string __toString()

__toString

Valeur de retour

string