24 require_once
'./Services/WorkflowEngine/classes/class.ilWorkflowEngine.php';
72 require_once(
'./Services/GlobalCache/classes/class.ilGlobalCache.php');
74 $cached_listeners = $ilGlobalCache->get(
'listeners');
75 if (is_array($cached_listeners)) {
76 $this->listener = $cached_listeners;
83 $this->listener =
array();
85 $sql =
"SELECT * FROM il_event_handling".
86 " WHERE type = ".$ilDB->quote(
"listen",
"text");
87 $res = $ilDB->query($sql);
88 while(
$row = $ilDB->fetchAssoc(
$res))
90 $this->listener[
$row[
"id"]][] = $row[
"component"];
93 $ilGlobalCache->set(
'listeners', $this->listener);
105 function raise($a_component, $a_event, $a_parameter =
"")
107 if (is_array($this->listener[$a_component]))
109 foreach ($this->listener[$a_component] as
$listener)
112 $last_slash = strripos($listener,
'/');
113 $comp = substr($listener,0,$last_slash);
114 $class =
'il'.substr($listener,$last_slash + 1).
'AppEventListener';
115 $file =
"./".$listener.
"/classes/class.".$class.
".php";
118 #$comp = explode("/", $listener); 119 #$class = "il".$comp[1]."AppEventListener"; 120 #$file = "./".$listener."/classes/class.".$class.".php"; 126 call_user_func(
array($class,
'handleEvent'), $a_component, $a_event, $a_parameter);
132 include_once(
"./Services/Component/classes/class.ilPluginAdmin.php");
134 foreach ($plugins as $pl)
138 $plugin->handleEvent($a_component, $a_event, $a_parameter);
142 $workflow_engine->handleEvent($a_component, $a_event, $a_parameter);
static getActivePluginsForSlot($a_ctype, $a_cname, $a_slot_id)
Get all active plugins for a slot.
static getInstance($component)
ilWorkflowEngine is part of the petri net based workflow engine.
static getPluginObject($a_ctype, $a_cname, $a_slot_id, $a_pname)
Get Plugin Object.
Create styles array
The data for the language used.
__construct()
Constructor.
if(!file_exists("$old.txt")) if($old===$new) if(file_exists("$new.txt")) $file