10 * @copyright 2014 Christian Weiske
11 * @license http://www.gnu.org/licenses/agpl.html GNU AGPL v3
12 * @link http://cweiske.de/php-sqllint.htm
17 * Class autoloader, PSR-0 compliant.
20 * @package PHP-SQLlint
22 * @copyright 2014 Christian Weiske
23 * @license http://www.gnu.org/licenses/agpl.html GNU AGPL v3
24 * @version Release: @package_version@
25 * @link http://cweiske.de/php-sqllint.htm
30 * Load the given class
32 * @param string $class Class name
36 public function load($class)
38 $file = strtr($class, '_\\', '//') . '.php';
39 if (stream_resolve_include_path($file)) {
45 * Register this autoloader
49 public static function register()
52 get_include_path() . PATH_SEPARATOR . __DIR__ . '/../'
54 spl_autoload_register(array(new self(), 'load'));