Ubiquity
2.5.2
php rapid development framework
Loading...
Searching...
No Matches
AbstractSession.php
Go to the documentation of this file.
1
<?php
2
3
namespace
Ubiquity\utils\http\session
;
4
5
use
Ubiquity\utils\http\session\protection\VerifySessionCsrfInterface
;
6
use
Ubiquity\utils\http\session\protection\VerifyCsrfToken
;
7
16
abstract
class
AbstractSession
{
17
protected
?
string
$name
;
18
protected
VerifySessionCsrfInterface
$verifyCsrf
;
19
20
public
function
__construct
(?
VerifySessionCsrfInterface
$verifyCsrf
=
null
) {
21
$this->verifyCsrf = (
$verifyCsrf
??=
new
VerifyCsrfToken
( $this ));
22
}
23
24
abstract
public
function
get
(
string
$key, $default =
null
);
25
26
abstract
public
function
set
(
string
$key, $value);
27
28
abstract
public
function
terminate
(): void;
29
30
abstract
public
function
start
(
string
$name
=
null
);
31
32
abstract
public
function
isStarted
(): bool;
33
34
abstract
public
function
exists
(
string
$key): bool;
35
36
abstract
public
function
getAll
(): array;
37
38
abstract
public
function
delete
(
string
$key);
39
40
abstract
public
function
visitorCount
(): int;
41
47
public
function
regenerateId
(
bool
$deleteOldSession=
false
): bool {
48
return false;
49
}
50
51
public
function
getVerifyCsrf
():
VerifySessionCsrfInterface
{
52
return $this->verifyCsrf;
53
}
54
}
55
Ubiquity\utils\http\session\AbstractSession
Ubiquity\utils\http\session$AbstractSession This class is part of Ubiquity.
Definition
AbstractSession.php:16
Ubiquity\utils\http\session\AbstractSession\start
start(string $name=null)
Ubiquity\utils\http\session\AbstractSession\$verifyCsrf
VerifySessionCsrfInterface $verifyCsrf
Definition
AbstractSession.php:18
Ubiquity\utils\http\session\AbstractSession\visitorCount
visitorCount()
Ubiquity\utils\http\session\AbstractSession\isStarted
isStarted()
Ubiquity\utils\http\session\AbstractSession\exists
exists(string $key)
Ubiquity\utils\http\session\AbstractSession\getVerifyCsrf
getVerifyCsrf()
Definition
AbstractSession.php:51
Ubiquity\utils\http\session\AbstractSession\regenerateId
regenerateId(bool $deleteOldSession=false)
Re-generates the session id.
Definition
AbstractSession.php:47
Ubiquity\utils\http\session\AbstractSession\__construct
__construct(?VerifySessionCsrfInterface $verifyCsrf=null)
Definition
AbstractSession.php:20
Ubiquity\utils\http\session\AbstractSession\$name
string $name
Definition
AbstractSession.php:17
Ubiquity\utils\http\session\AbstractSession\terminate
terminate()
Ubiquity\utils\http\session\AbstractSession\getAll
getAll()
Ubiquity\utils\http\session\protection\VerifyCsrfToken
Ubiquity\utils\http\session\protection$VerifyCsrfToken This class is part of Ubiquity.
Definition
VerifyCsrfToken.php:17
Ubiquity\utils\http\session\protection\VerifySessionCsrfInterface
Ubiquity\utils\http\session\protection$VerifyCsrfInterface This class is part of Ubiquity.
Definition
VerifySessionCsrfInterface.php:13
Ubiquity\utils\http\session
Definition
AbstractSession.php:3
C:
Users
myadd
Documents
GitHub
ubiquity-doc-api
vendor
phpmv
ubiquity
src
Ubiquity
utils
http
session
AbstractSession.php
Generated on Sun Dec 10 2023 15:04:27 for
Ubiquity
by
doxygen
1.9.8