ILIAS  trunk Revision v11.0_alpha-1831-g8615d53dadb
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ILIAS\Survey\Editing\EditSessionRepo Class Reference

Stores access codes of anonymous session. More...

+ Collaboration diagram for ILIAS\Survey\Editing\EditSessionRepo:

Public Member Functions

 __construct ()
 
 setConstraintStructure (?array $structure)
 
 getConstraintStructure ()
 
 clearConstraintStructure ()
 
 setConstraintElements (?array $elements)
 
 getConstraintElements ()
 
 clearConstraintElements ()
 
 setMoveSurveyQuestions (int $survey_id, array $question_ids)
 
 clearMoveSurveyQuestions ()
 
 getMoveSurveyQuestions ()
 
 getMoveSurveyId ()
 
 setQuestionClipboard (int $ref_id, int $page, string $mode, array $question_ids)
 
 clearQuestionClipboard ($ref_id)
 
 getQuestionClipboardSourcePage (int $ref_id)
 
 getQuestionClipboardMode (int $ref_id)
 
 getQuestionClipboardQuestions (int $ref_id)
 
 isQuestionClipboardEmpty (int $ref_id)
 
 setPoolChoice (int $id)
 
 getPoolChoice ()
 
 setExternalText (string $text)
 
 getExternalText ()
 

Protected Member Functions

 getClipKey (int $ref_id)
 

Protected Attributes

const KEY_BASE = "svy_edit_"
 
const KEY_CONSTRAINT_STRUCTURE = self::KEY_BASE . "constraints"
 
const KEY_CONSTRAINT_ELEMENTS = self::KEY_BASE . "elements"
 
const KEY_EXT_TEXT = self::KEY_BASE . "ext_text"
 

Detailed Description

Stores access codes of anonymous session.

Author
Alexander Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

Definition at line 27 of file class.EditSessionRepo.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Survey\Editing\EditSessionRepo::__construct ( )

Definition at line 34 of file class.EditSessionRepo.php.

35  {
36  }

Member Function Documentation

◆ clearConstraintElements()

ILIAS\Survey\Editing\EditSessionRepo::clearConstraintElements ( )

Definition at line 63 of file class.EditSessionRepo.php.

References ilSession\clear().

63  : void
64  {
65  \ilSession::clear(self::KEY_CONSTRAINT_ELEMENTS);
66  }
static clear(string $a_var)
+ Here is the call graph for this function:

◆ clearConstraintStructure()

ILIAS\Survey\Editing\EditSessionRepo::clearConstraintStructure ( )

Definition at line 48 of file class.EditSessionRepo.php.

References ilSession\clear().

48  : void
49  {
50  \ilSession::clear(self::KEY_CONSTRAINT_STRUCTURE);
51  }
static clear(string $a_var)
+ Here is the call graph for this function:

◆ clearMoveSurveyQuestions()

ILIAS\Survey\Editing\EditSessionRepo::clearMoveSurveyQuestions ( )

Definition at line 74 of file class.EditSessionRepo.php.

References ilSession\clear().

74  : void
75  {
76  \ilSession::clear(self::KEY_BASE . "move_svy_id");
77  \ilSession::clear(self::KEY_BASE . "move_svy_qids");
78  }
static clear(string $a_var)
+ Here is the call graph for this function:

◆ clearQuestionClipboard()

ILIAS\Survey\Editing\EditSessionRepo::clearQuestionClipboard (   $ref_id)

Definition at line 117 of file class.EditSessionRepo.php.

References $ref_id, ilSession\clear(), and ILIAS\Survey\Editing\EditSessionRepo\getClipKey().

117  : void
118  {
120  }
$ref_id
Definition: ltiauth.php:65
static clear(string $a_var)
+ Here is the call graph for this function:

◆ getClipKey()

◆ getConstraintElements()

ILIAS\Survey\Editing\EditSessionRepo::getConstraintElements ( )

Definition at line 58 of file class.EditSessionRepo.php.

References ILIAS\GlobalScreen\get().

58  : ?array
59  {
60  return \ilSession::get(self::KEY_CONSTRAINT_ELEMENTS);
61  }
get(string $class_name)
+ Here is the call graph for this function:

◆ getConstraintStructure()

ILIAS\Survey\Editing\EditSessionRepo::getConstraintStructure ( )

Definition at line 43 of file class.EditSessionRepo.php.

References ILIAS\GlobalScreen\get().

43  : ?array
44  {
45  return \ilSession::get(self::KEY_CONSTRAINT_STRUCTURE);
46  }
get(string $class_name)
+ Here is the call graph for this function:

◆ getExternalText()

ILIAS\Survey\Editing\EditSessionRepo::getExternalText ( )

Definition at line 175 of file class.EditSessionRepo.php.

References ilSession\get().

175  : string
176  {
177  return (string) \ilSession::get(self::KEY_EXT_TEXT);
178  }
static get(string $a_var)
+ Here is the call graph for this function:

◆ getMoveSurveyId()

ILIAS\Survey\Editing\EditSessionRepo::getMoveSurveyId ( )

Definition at line 88 of file class.EditSessionRepo.php.

References ILIAS\GlobalScreen\get(), and ilSession\has().

88  : int
89  {
90  if (\ilSession::has(self::KEY_BASE . "move_svy_id")) {
91  return \ilSession::get(self::KEY_BASE . "move_svy_id");
92  }
93  return 0;
94  }
get(string $class_name)
static has($a_var)
+ Here is the call graph for this function:

◆ getMoveSurveyQuestions()

ILIAS\Survey\Editing\EditSessionRepo::getMoveSurveyQuestions ( )

Definition at line 80 of file class.EditSessionRepo.php.

References ILIAS\GlobalScreen\get(), and ilSession\has().

80  : array
81  {
82  if (\ilSession::has(self::KEY_BASE . "move_svy_qids")) {
83  return \ilSession::get(self::KEY_BASE . "move_svy_qids");
84  }
85  return [];
86  }
get(string $class_name)
static has($a_var)
+ Here is the call graph for this function:

◆ getPoolChoice()

ILIAS\Survey\Editing\EditSessionRepo::getPoolChoice ( )

Definition at line 162 of file class.EditSessionRepo.php.

References ILIAS\GlobalScreen\get(), and ilSession\has().

162  : int
163  {
164  if (\ilSession::has(self::KEY_BASE . "pool_choice")) {
165  return \ilSession::get(self::KEY_BASE . "pool_choice");
166  }
167  return 0;
168  }
get(string $class_name)
static has($a_var)
+ Here is the call graph for this function:

◆ getQuestionClipboardMode()

ILIAS\Survey\Editing\EditSessionRepo::getQuestionClipboardMode ( int  $ref_id)

Definition at line 131 of file class.EditSessionRepo.php.

References $data, ilSession\get(), ILIAS\Survey\Editing\EditSessionRepo\getClipKey(), and ilSession\has().

131  : string
132  {
133  if (\ilSession::has($this->getClipKey($ref_id))) {
135  return $data["mode"];
136  }
137  return "";
138  }
static get(string $a_var)
$ref_id
Definition: ltiauth.php:65
static has($a_var)
+ Here is the call graph for this function:

◆ getQuestionClipboardQuestions()

ILIAS\Survey\Editing\EditSessionRepo::getQuestionClipboardQuestions ( int  $ref_id)

Definition at line 140 of file class.EditSessionRepo.php.

References $data, ilSession\get(), ILIAS\Survey\Editing\EditSessionRepo\getClipKey(), and ilSession\has().

140  : array
141  {
142  if (\ilSession::has($this->getClipKey($ref_id))) {
144  return $data["question_ids"];
145  }
146  return [];
147  }
static get(string $a_var)
$ref_id
Definition: ltiauth.php:65
static has($a_var)
+ Here is the call graph for this function:

◆ getQuestionClipboardSourcePage()

ILIAS\Survey\Editing\EditSessionRepo::getQuestionClipboardSourcePage ( int  $ref_id)

Definition at line 122 of file class.EditSessionRepo.php.

References $data, ilSession\get(), ILIAS\Survey\Editing\EditSessionRepo\getClipKey(), ilSession\has(), and null.

122  : ?int
123  {
124  if (\ilSession::has($this->getClipKey($ref_id))) {
126  return $data["source_page"];
127  }
128  return null;
129  }
static get(string $a_var)
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
$ref_id
Definition: ltiauth.php:65
static has($a_var)
+ Here is the call graph for this function:

◆ isQuestionClipboardEmpty()

ILIAS\Survey\Editing\EditSessionRepo::isQuestionClipboardEmpty ( int  $ref_id)

Definition at line 149 of file class.EditSessionRepo.php.

References ILIAS\Survey\Editing\EditSessionRepo\getClipKey(), and ilSession\has().

149  : bool
150  {
151  if (\ilSession::has($this->getClipKey($ref_id))) {
152  return false;
153  }
154  return true;
155  }
$ref_id
Definition: ltiauth.php:65
static has($a_var)
+ Here is the call graph for this function:

◆ setConstraintElements()

ILIAS\Survey\Editing\EditSessionRepo::setConstraintElements ( ?array  $elements)

Definition at line 53 of file class.EditSessionRepo.php.

References ilSession\set().

53  : void
54  {
55  \ilSession::set(self::KEY_CONSTRAINT_ELEMENTS, $elements);
56  }
static set(string $a_var, $a_val)
Set a value.
+ Here is the call graph for this function:

◆ setConstraintStructure()

ILIAS\Survey\Editing\EditSessionRepo::setConstraintStructure ( ?array  $structure)

Definition at line 38 of file class.EditSessionRepo.php.

References ilSession\set().

38  : void
39  {
40  \ilSession::set(self::KEY_CONSTRAINT_STRUCTURE, $structure);
41  }
$structure
TOTAL STRUCTURE.
static set(string $a_var, $a_val)
Set a value.
+ Here is the call graph for this function:

◆ setExternalText()

ILIAS\Survey\Editing\EditSessionRepo::setExternalText ( string  $text)

Definition at line 170 of file class.EditSessionRepo.php.

References ilSession\set().

170  : void
171  {
172  \ilSession::set(self::KEY_EXT_TEXT, $text);
173  }
static set(string $a_var, $a_val)
Set a value.
+ Here is the call graph for this function:

◆ setMoveSurveyQuestions()

ILIAS\Survey\Editing\EditSessionRepo::setMoveSurveyQuestions ( int  $survey_id,
array  $question_ids 
)

Definition at line 68 of file class.EditSessionRepo.php.

References ilSession\set().

68  : void
69  {
70  \ilSession::set(self::KEY_BASE . "move_svy_id", $survey_id);
71  \ilSession::set(self::KEY_BASE . "move_svy_qids", $question_ids);
72  }
static set(string $a_var, $a_val)
Set a value.
+ Here is the call graph for this function:

◆ setPoolChoice()

ILIAS\Survey\Editing\EditSessionRepo::setPoolChoice ( int  $id)

Definition at line 157 of file class.EditSessionRepo.php.

References ilSession\set().

157  : void
158  {
159  \ilSession::set(self::KEY_BASE . "pool_choice", $id);
160  }
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
static set(string $a_var, $a_val)
Set a value.
+ Here is the call graph for this function:

◆ setQuestionClipboard()

ILIAS\Survey\Editing\EditSessionRepo::setQuestionClipboard ( int  $ref_id,
int  $page,
string  $mode,
array  $question_ids 
)

Definition at line 101 of file class.EditSessionRepo.php.

References ILIAS\Survey\Editing\EditSessionRepo\getClipKey(), and ilSession\set().

106  : void {
108  $this->getClipKey($ref_id),
109  [
110  "source_page" => $page,
111  "mode" => $mode,
112  "question_ids" => $question_ids
113  ]
114  );
115  }
$ref_id
Definition: ltiauth.php:65
static set(string $a_var, $a_val)
Set a value.
+ Here is the call graph for this function:

Field Documentation

◆ KEY_BASE

const ILIAS\Survey\Editing\EditSessionRepo::KEY_BASE = "svy_edit_"
protected

Definition at line 29 of file class.EditSessionRepo.php.

◆ KEY_CONSTRAINT_ELEMENTS

const ILIAS\Survey\Editing\EditSessionRepo::KEY_CONSTRAINT_ELEMENTS = self::KEY_BASE . "elements"
protected

Definition at line 31 of file class.EditSessionRepo.php.

◆ KEY_CONSTRAINT_STRUCTURE

const ILIAS\Survey\Editing\EditSessionRepo::KEY_CONSTRAINT_STRUCTURE = self::KEY_BASE . "constraints"
protected

Definition at line 30 of file class.EditSessionRepo.php.

◆ KEY_EXT_TEXT

const ILIAS\Survey\Editing\EditSessionRepo::KEY_EXT_TEXT = self::KEY_BASE . "ext_text"
protected

Definition at line 32 of file class.EditSessionRepo.php.


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