5 require_once __DIR__ .
'/config.inc.php';
23 $arrParameter = func_get_args();
25 if(empty($arrParameter))
26 throw new \Exception (
"no parameter given for execution");
28 if(!is_string($arrParameter[0]))
31 # get instance of queue and work with a copy of it
75 if(!empty($arrDefinition[
'DEFAULT']) &&
true == (boolean) $arrDefinition[
'DEFAULT'])
116 if(!is_string($strPath))
119 if(!is_callable($strCallback))
122 if(!is_string($strFilenameMatch))
125 if(!is_dir($strPath))
126 throw new \Exception (
'given path is not an directory: ' . $strPath);
128 $resDirHandle = opendir($strPath);
130 if(!is_resource($resDirHandle))
131 throw new \Exception (
'could not read directory: ' . $strPath);
133 while($strFile = readdir($resDirHandle))
134 if(is_file($strPath.$strFile) && fnmatch($strFilenameMatch, $strFile))
135 call_user_func_array($strCallback, array($strPath.$strFile));
137 closedir($resDirHandle);
160 if(!is_string($strGroup))
163 if(!is_null($cloAdditionalHandler) && !is_callable($cloAdditionalHandler))
166 if(!is_file($strFile) || !file_exists($strFile))
167 throw new \Exception (
"given file is not a file or doesn't exists: $strFile");
169 if(!is_readable($strFile))
170 throw new \Exception (
"given file is not readable: $strFile");
172 $arrDefinitions = parse_ini_file($strFile,
true);
176 foreach($arrDefinitions AS $strDefinitionAlias => $arrDefinition) {
179 if(!is_null($cloAdditionalHandler))