ArraySessionHandler
class ArraySessionHandler implements SessionHandlerInterface
Traits
Properties
| protected array | $storage | The array of stored values. |
Methods
Get the number of seconds until the given DateTime.
Get the "available at" UNIX timestamp.
If the given value is an interval, convert it to a DateTime instance.
Given a start time, format the total run time for human readability.
Create a new array driven handler instance.
No description
No description
No description
No description
No description
No description
Get the expiration time of the session.
Details
in
InteractsWithTime at line 17
protected int
secondsUntil(DateInterval|DateTimeInterface|int $delay)
Get the number of seconds until the given DateTime.
in
InteractsWithTime at line 29
protected int
availableAt(DateInterval|DateTimeInterface|int|null $delay = 0)
Get the "available at" UNIX timestamp.
in
InteractsWithTime at line 41
protected DateTimeInterface|int
parseDateInterval(DateInterval|DateTimeInterface|int|null $delay)
If the given value is an interval, convert it to a DateTime instance.
in
InteractsWithTime at line 57
protected int
currentTime()
Get the current system time as a UNIX timestamp.
in
InteractsWithTime at line 65
protected string
runTimeForHumans(float $startTime, float|null $endTime = null)
Given a start time, format the total run time for human readability.
at line 24
__construct(int $minutes)
Create a new array driven handler instance.
at line 29
bool
open(string $savePath, string $sessionName)
No description
at line 34
bool
close()
No description
at line 39
false|string
read(string $sessionId)
No description
at line 56
bool
write(string $sessionId, string $data)
No description
at line 66
bool
destroy(string $sessionId)
No description
at line 75
int
gc(int $lifetime)
No description
at line 94
protected int
calculateExpiration(int $seconds)
Get the expiration time of the session.