ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilAccessibilityCriterionTypeFactory 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 ilAccessibilityCriterionTypeFactory:
+ Collaboration diagram for ilAccessibilityCriterionTypeFactory:

Public Member Functions

 __construct (ilRbacReview $rbacReview, ilObjectDataCache $objectCache)
 
 getTypesByIdentMap ()
 
 hasOnlyOneCriterion ()
 
 findByTypeIdent (string $typeIdent, bool $useFallback=false)
 
 getTypesByIdentMap ()
 
 hasOnlyOneCriterion ()
 
 findByTypeIdent (string $typeIdent, bool $useFallback=false)
 

Protected Attributes

array $types = []
 

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 Class ilAccessibilityCriterionTypeFactory

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

Constructor & Destructor Documentation

◆ __construct()

ilAccessibilityCriterionTypeFactory::__construct ( ilRbacReview  $rbacReview,
ilObjectDataCache  $objectCache 
)

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

28 {
29 $usrLanguageCriterion = new ilAccessibilityUserHasLanguageCriterion();
30
31 $this->types = [
32 $usrLanguageCriterion->getTypeIdent() => $usrLanguageCriterion
33 ];
34 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

Member Function Documentation

◆ findByTypeIdent()

ilAccessibilityCriterionTypeFactory::findByTypeIdent ( string  $typeIdent,
bool  $useFallback = false 
)
Parameters
string$typeIdent
bool$useFallback
Returns
ilAccessibilityCriterionType
Exceptions
ilAccessibilityCriterionTypeNotFoundException

Implements ilAccessibilityCriterionTypeFactoryInterface.

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

51 {
52 if (isset($this->types[$typeIdent])) {
53 return $this->types[$typeIdent];
54 }
55
56 if ($useFallback) {
58 }
59
61 "Did not find criterion type by ident: %s",
62 var_export($typeIdent, true)
63 ));
64 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class ilAccessibilityNullCriterion.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

◆ getTypesByIdentMap()

ilAccessibilityCriterionTypeFactory::getTypesByIdentMap ( )

◆ hasOnlyOneCriterion()

ilAccessibilityCriterionTypeFactory::hasOnlyOneCriterion ( )
Returns
bool

Implements ilAccessibilityCriterionTypeFactoryInterface.

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

41 : bool
42 {
43 if (count($this->types) == 1) {
44 return true;
45 } else {
46 return false;
47 }
48 }

Field Documentation

◆ $types

array ilAccessibilityCriterionTypeFactory::$types = []
protected

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

Referenced by getTypesByIdentMap().


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