ILIAS  trunk Revision v11.0_alpha-1761-g6dbbfa7b760
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilAccessibilitySequentialDocumentEvaluation Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Inheritance diagram for ilAccessibilitySequentialDocumentEvaluation:
+ Collaboration diagram for ilAccessibilitySequentialDocumentEvaluation:

Public Member Functions

 __construct (ilAccessibilityDocumentCriteriaEvaluation $evaluation, ilObjUser $user, ilLogger $log, array $possibleDocuments)
 
 document ()
 
 hasDocument ()
 

Protected Member Functions

 getMatchingDocuments ()
 

Protected Attributes

ilAccessibilityDocumentCriteriaEvaluation $evaluation
 
ilObjUser $user
 
array $matchingDocuments = null
 
array $possibleDocuments = []
 
ilLogger $log
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Interface ilAccessibilitySequentialDocumentEvaluation

Definition at line 22 of file class.ilAccessibilitySequentialDocumentEvaluation.php.

Constructor & Destructor Documentation

◆ __construct()

ilAccessibilitySequentialDocumentEvaluation::__construct ( ilAccessibilityDocumentCriteriaEvaluation  $evaluation,
ilObjUser  $user,
ilLogger  $log,
array  $possibleDocuments 
)

Member Function Documentation

◆ document()

ilAccessibilitySequentialDocumentEvaluation::document ( )
Returns
ilAccessibilitySignableDocument
Exceptions
ilAccessibilityNoSignableDocumentFoundException

Implements ilAccessibilityDocumentEvaluation.

Definition at line 73 of file class.ilAccessibilitySequentialDocumentEvaluation.php.

References getMatchingDocuments(), and ILIAS\Repository\user().

74  {
76  if (count($matchingDocuments) > 0) {
77  return $matchingDocuments[0];
78  }
79 
81  'Could not find any accessibility control concept document for the passed user (id: %s|login: %s)',
82  $this->user->getId(),
83  $this->user->getLogin()
84  ));
85  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
+ Here is the call graph for this function:

◆ getMatchingDocuments()

ilAccessibilitySequentialDocumentEvaluation::getMatchingDocuments ( )
protected
Returns
ilAccessibilitySignableDocument[]

Definition at line 47 of file class.ilAccessibilitySequentialDocumentEvaluation.php.

References $matchingDocuments, null, and ILIAS\Repository\user().

Referenced by document(), and hasDocument().

47  : array
48  {
49  if (null === $this->matchingDocuments) {
50  $this->matchingDocuments = [];
51 
52  $this->log->debug(sprintf(
53  'Evaluating document for user "%s" (id: %s) ...',
54  $this->user->getLogin(),
55  $this->user->getId()
56  ));
57 
58  foreach ($this->possibleDocuments as $document) {
59  if ($this->evaluation->evaluate($document)) {
60  $this->matchingDocuments[] = $document;
61  }
62  }
63 
64  $this->log->debug(sprintf(
65  '%s matching document(s) found',
66  count($this->matchingDocuments)
67  ));
68  }
69 
71  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ hasDocument()

ilAccessibilitySequentialDocumentEvaluation::hasDocument ( )
Returns
bool

Implements ilAccessibilityDocumentEvaluation.

Definition at line 87 of file class.ilAccessibilitySequentialDocumentEvaluation.php.

References getMatchingDocuments().

87  : bool
88  {
89  return count($this->getMatchingDocuments()) > 0;
90  }
+ Here is the call graph for this function:

Field Documentation

◆ $evaluation

ilAccessibilityDocumentCriteriaEvaluation ilAccessibilitySequentialDocumentEvaluation::$evaluation
protected

Definition at line 24 of file class.ilAccessibilitySequentialDocumentEvaluation.php.

Referenced by __construct().

◆ $log

ilLogger ilAccessibilitySequentialDocumentEvaluation::$log
protected

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

Referenced by __construct().

◆ $matchingDocuments

array ilAccessibilitySequentialDocumentEvaluation::$matchingDocuments = null
protected

◆ $possibleDocuments

array ilAccessibilitySequentialDocumentEvaluation::$possibleDocuments = []
protected

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

Referenced by __construct().

◆ $user

ilObjUser ilAccessibilitySequentialDocumentEvaluation::$user
protected

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

Referenced by __construct().


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