ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
class.ilObjectListGUIFactory.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4include_once './Services/Object/classes/class.ilObjectListGUI.php';
5
15{
17 {
18 global $DIC;
19
20 $objDefinition = $DIC["objDefinition"];
21
22 $class = $objDefinition->getClassName($a_type);
23 $location = $objDefinition->getLocation($a_type);
24 $full_class = "ilObj" . $class . "ListGUI";
25 if (file_exists($location . "/class." . $full_class . ".php")) {
26 include_once($location . "/class." . $full_class . ".php");
27 return new $full_class($a_context);
28 }
29
30 // php7-todo JL: throw exception instead?
31 return new ilObjectListGUI($a_context);
32 }
33} // END class.ilObjectListGUIFactory
$location
Definition: buildRTE.php:44
An exception for terminatinating execution or to throw for unit testing.
Class ilObjectListGUIFactory.
static _getListGUIByType($a_type, $a_context=ilObjectListGUI::CONTEXT_REPOSITORY)
Class ilObjectListGUI.
$a_type
Definition: workflow.php:92
$DIC
Definition: xapitoken.php:46