ILIAS  release_7 Revision v7.30-3-g800a261c036
class.ilLTIRouterGUI.php
Go to the documentation of this file.
1<?php
2
14{
15
17 protected $ilCtrl;
18
19 public function __construct()
20 {
21 global $ilCtrl;
22 $this->ilCtrl = $ilCtrl;
23 }
24
28 public function executeCommand()
29 {
30 $next_class = $this->ilCtrl->getNextClass($this);
31 $class_file = $this->ilCtrl->lookupClassPath($next_class);
32
33 if (is_file($class_file)) {
34 include_once($class_file);
35 $gui = $next_class::getInstance(); // Singleton!
36 $this->ilCtrl->forwardCommand($gui);
37 } else {
38 ilUtil::sendFailure('GUI-Class not found! (' . $next_class . ')');
39 }
40 }
41}
An exception for terminatinating execution or to throw for unit testing.
This class provides processing control methods.
getNextClass($a_gui_class=null)
Get next class in the control path from the current class to the target command class.
lookupClassPath($a_class_name)
Get class path that can be used in include statements for a given class name.
forwardCommand($a_gui_object)
Forward flow of control to next gui class this invokes the executeCommand() method of the gui object ...
Service ilViewRouterGUI This service is used by LTI.
executeCommand()
The only thing this execute Command does is forward the command in the command chain.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.