protected static function psr_classloader($class) {
        // Iterate through each PSR-4 namespace prefix.
        foreach (self::$psr4namespaces as $prefix => $path) {
            $file = self::get_class_file($class, $prefix, $path, array('\\'));
            if (!empty($file) && file_exists($file)) {
                return $file;
            }
        }

        // Iterate through each PSR-0 namespace prefix.
        foreach (self::$psr0namespaces as $prefix => $path) {
            $file = self::get_class_file($class, $prefix, $path, array('\\', '_'));
            if (!empty($file) && file_exists($file)) {
                return $file;
            }
        }

        return false;
    }