AbstractSession
in package
implements
SessionInterface, ArrayAccess, Countable, IteratorAggregate
AbstractYes
Abstract session class
Tags
Table of Contents
Interfaces
- SessionInterface
- Session interface
- ArrayAccess
- Countable
- IteratorAggregate
Methods
- __get() : mixed
- Magic get method to return the value of values[$name].
- __isset() : bool
- Return the isset value of values[$name].
- __set() : void
- Magic set method to set values[$name].
- __unset() : void
- Unset values[$name].
- count() : int
- Method to get the count of data in the session
- getIterator() : ArrayIterator
- Method to iterate over the session
- kill() : void
- Destroy the session
- offsetExists() : bool
- ArrayAccess offsetExists
- offsetGet() : mixed
- ArrayAccess offsetGet
- offsetSet() : void
- ArrayAccess offsetSet
- offsetUnset() : void
- ArrayAccess offsetUnset
- setRequestValue() : AbstractSession
- Set a request-based value
- setTimedValue() : AbstractSession
- Set a time-based value
- toArray() : array<string|int, mixed>
- Get the session values as an array
Methods
__get()
Magic get method to return the value of values[$name].
public
abstract __get(string $name) : mixed
Parameters
- $name : string
__isset()
Return the isset value of values[$name].
public
abstract __isset(string $name) : bool
Parameters
- $name : string
Return values
bool__set()
Magic set method to set values[$name].
public
abstract __set(string $name, mixed $value) : void
Parameters
- $name : string
- $value : mixed
__unset()
Unset values[$name].
public
abstract __unset(string $name) : void
Parameters
- $name : string
count()
Method to get the count of data in the session
public
count() : int
Return values
intgetIterator()
Method to iterate over the session
public
getIterator() : ArrayIterator
Return values
ArrayIteratorkill()
Destroy the session
public
abstract kill() : void
offsetExists()
ArrayAccess offsetExists
public
offsetExists(mixed $offset) : bool
Parameters
- $offset : mixed
Return values
booloffsetGet()
ArrayAccess offsetGet
public
offsetGet(mixed $offset) : mixed
Parameters
- $offset : mixed
offsetSet()
ArrayAccess offsetSet
public
offsetSet(mixed $offset, mixed $value) : void
Parameters
- $offset : mixed
- $value : mixed
offsetUnset()
ArrayAccess offsetUnset
public
offsetUnset(mixed $offset) : void
Parameters
- $offset : mixed
setRequestValue()
Set a request-based value
public
abstract setRequestValue(string $key, mixed $value[, int $hops = 1 ]) : AbstractSession
Parameters
- $key : string
- $value : mixed
- $hops : int = 1
Return values
AbstractSessionsetTimedValue()
Set a time-based value
public
abstract setTimedValue(string $key, mixed $value[, int $expire = 300 ]) : AbstractSession
Parameters
- $key : string
- $value : mixed
- $expire : int = 300
Return values
AbstractSessiontoArray()
Get the session values as an array
public
abstract toArray() : array<string|int, mixed>