ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ILIAS\Container\Classification\ClassificationSessionRepository Class Reference
+ Collaboration diagram for ILIAS\Container\Classification\ClassificationSessionRepository:

Public Member Functions

 __construct (int $base_ref_id)
 
 unsetAll ()
 
 unsetValueForProvider (string $provider)
 
 isEmpty ()
 
 getValueForProvider (string $provider)
 
 setValueForProvider (string $provider, array $value)
 

Data Fields

const BASE_SESSION_KEY = 'clsfct'
 

Protected Attributes

string $key
 
int $base_ref_id
 

Detailed Description

Definition at line 23 of file class.ClassificationSessionRepository.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Container\Classification\ClassificationSessionRepository::__construct ( int  $base_ref_id)

Member Function Documentation

◆ getValueForProvider()

ILIAS\Container\Classification\ClassificationSessionRepository::getValueForProvider ( string  $provider)

Definition at line 55 of file class.ClassificationSessionRepository.php.

55 : array
56 {
57 if (\ilSession::has($this->key)) {
58 $vals = \ilSession::get($this->key);
59 return $vals[$provider] ?? [];
60 }
61 return [];
62 }
static get(string $a_var)
static has($a_var)
$provider
Definition: ltitoken.php:80

References $provider, ilSession\get(), and ilSession\has().

+ Here is the call graph for this function:

◆ isEmpty()

ILIAS\Container\Classification\ClassificationSessionRepository::isEmpty ( )

Definition at line 50 of file class.ClassificationSessionRepository.php.

50 : bool
51 {
52 return !\ilSession::has($this->key);
53 }

References ilSession\has().

+ Here is the call graph for this function:

◆ setValueForProvider()

ILIAS\Container\Classification\ClassificationSessionRepository::setValueForProvider ( string  $provider,
array  $value 
)

Definition at line 64 of file class.ClassificationSessionRepository.php.

64 : void
65 {
66 $vals = [];
67 if (\ilSession::has($this->key)) {
68 $vals = \ilSession::get($this->key);
69 }
70 $vals[$provider] = $value;
71 \ilSession::set($this->key, $vals);
72 }
static set(string $a_var, $a_val)
Set a value.

References $provider, ilSession\get(), ilSession\has(), and ilSession\set().

+ Here is the call graph for this function:

◆ unsetAll()

ILIAS\Container\Classification\ClassificationSessionRepository::unsetAll ( )

Definition at line 36 of file class.ClassificationSessionRepository.php.

36 : void
37 {
38 \ilSession::clear($this->key);
39 }
static clear(string $a_var)

References ilSession\clear().

+ Here is the call graph for this function:

◆ unsetValueForProvider()

ILIAS\Container\Classification\ClassificationSessionRepository::unsetValueForProvider ( string  $provider)

Definition at line 41 of file class.ClassificationSessionRepository.php.

41 : void
42 {
43 if (\ilSession::has($this->key)) {
44 $vals = \ilSession::get($this->key);
45 unset($vals[$provider]);
46 \ilSession::set($this->key, $vals);
47 }
48 }

References $provider, ilSession\get(), ilSession\has(), and ilSession\set().

+ Here is the call graph for this function:

Field Documentation

◆ $base_ref_id

int ILIAS\Container\Classification\ClassificationSessionRepository::$base_ref_id
protected

◆ $key

string ILIAS\Container\Classification\ClassificationSessionRepository::$key
protected

Definition at line 26 of file class.ClassificationSessionRepository.php.

◆ BASE_SESSION_KEY

const ILIAS\Container\Classification\ClassificationSessionRepository::BASE_SESSION_KEY = 'clsfct'

Definition at line 25 of file class.ClassificationSessionRepository.php.


The documentation for this class was generated from the following file: