diff options
Diffstat (limited to 'php-hoa-file-autoload.php')
-rw-r--r-- | php-hoa-file-autoload.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/php-hoa-file-autoload.php b/php-hoa-file-autoload.php new file mode 100644 index 0000000..7b15e41 --- /dev/null +++ b/php-hoa-file-autoload.php @@ -0,0 +1,18 @@ +<?php +/* Autoloader for hoa/file and its dependencies */ + +$vendor = '/usr/share/php'; + +// Dependencies +foreach ([ + $vendor . '/Hoa/Consistency/autoload.php' => true, + $vendor . '/Hoa/Event/autoload.php' => true, + $vendor . '/Hoa/Exception/autoload.php' => true, + $vendor . '/Hoa/Stream/autoload.php' => true, + $vendor . '/Hoa/Iterator/autoload.php' => true, + ] as $dep => $mandatory) { + if ($mandatory || file_exists($dep)) require_once($dep); +} + +$fedoraHoaLoader->addNamespace('Hoa\\File\\', __DIR__, true); + |