forked from bronto/bronto-api-php-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathautoload.php.dist
34 lines (27 loc) · 961 Bytes
/
autoload.php.dist
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<?php
/*
* Use vendor/autoload.php if you are using composer!
*/
define('DS', DIRECTORY_SEPARATOR);
define('BASE_PATH', dirname(__FILE__));
if (file_exists($file = __DIR__.'/functions.php')) {
require_once $file;
}
require_once BASE_PATH . '/vendor/symfony/src/Symfony/Component/ClassLoader/UniversalClassLoader.php';
require_once BASE_PATH . '/vendor/symfony/src/Symfony/Component/ClassLoader/ApcUniversalClassLoader.php';
use Symfony\Component\ClassLoader\UniversalClassLoader;
use Symfony\Component\ClassLoader\ApcUniversalClassLoader;
if (extension_loaded('apc')) {
$loader = new ApcUniversalClassLoader('bronto.');
} else {
$loader = new UniversalClassLoader();
}
$loader->registerNamespaces(array(
'Console' => BASE_PATH . '/bin',
'Symfony' => BASE_PATH . '/vendor/symfony/src',
));
$loader->registerPrefixes(array(
'Bronto_Tests' => BASE_PATH . '/tests',
'Bronto_' => BASE_PATH . '/src',
));
$loader->register();