ILIAS
release_5-4 Revision v5.4.26-12-gabc799a52e6
◀ ilDoc Overview
Bootstrap.php
Go to the documentation of this file.
1
<?
php
2
3
include_once __DIR__ .
'/Autoloader.php'
;
4
5
\Complex\Autoloader::Register
();
6
7
8
abstract
class
FilesystemRegexFilter
extends
RecursiveRegexIterator
9
{
10
protected
$regex
;
11
public
function
__construct
(
RecursiveIterator
$it,
$regex
)
12
{
13
$this->regex =
$regex
;
14
parent::__construct($it,
$regex
);
15
}
16
}
17
18
class
FilenameFilter
extends
FilesystemRegexFilter
19
{
20
// Filter files against the regex
21
public
function
accept
()
22
{
23
return
(!$this->isFile() || preg_match($this->regex, $this->getFilename()));
24
}
25
}
26
27
28
$srcFolder
= __DIR__ . DIRECTORY_SEPARATOR .
'src'
;
29
$srcDirectory
=
new
RecursiveDirectoryIterator
(
$srcFolder
);
30
31
$filteredFileList
=
new
FilenameFilter
(
$srcDirectory
,
'/(?:php)$/i'
);
32
$filteredFileList
=
new
FilenameFilter
(
$filteredFileList
,
'/^(?!.*(Complex|Exception)\.php).*$/i'
);
33
34
foreach
(
new
RecursiveIteratorIterator
(
$filteredFileList
) as $file) {
35
if
($file->isFile()) {
36
include_once $file;
37
}
38
}
RecursiveIterator
FilenameFilter
Definition:
Bootstrap.php:18
$srcDirectory
$srcDirectory
Definition:
Bootstrap.php:29
$filteredFileList
$filteredFileList
Definition:
Bootstrap.php:31
FilesystemRegexFilter\__construct
__construct(RecursiveIterator $it, $regex)
Definition:
Bootstrap.php:11
FilenameFilter\accept
accept()
Definition:
Bootstrap.php:21
RecursiveDirectoryIterator
FilesystemRegexFilter
Definition:
Bootstrap.php:8
Complex\Autoloader\Register
static Register()
Register the Autoloader with SPL.
Definition:
Autoloader.php:19
$srcFolder
$srcFolder
Definition:
Bootstrap.php:28
RecursiveIteratorIterator
RecursiveRegexIterator
FilesystemRegexFilter\$regex
$regex
Definition:
Bootstrap.php:10
php
libs
composer
vendor
markbaker
complex
classes
Bootstrap.php
Generated on Thu Jan 30 2025 19:01:16 for ILIAS by
1.8.13 (using
Doxyfile
)