public function load($class)
    {
        if ($this->psr0 and $this->loadPsr0($class)) {
            return true;
        }
        $namespace = '\\';
        $classPath = str_replace('\\', '/', $class) . '.php';
        while (true) {
            if ($this->loadFrom($classPath, $namespace)) {
                return true;
            }
            $pos = strpos($classPath, '/');
            if ($pos === false) {
                if (! $this->psr0) {
                    break;
                }
                $pos = strpos($classPath, '_');
                if ($pos === false) {
                    break;
                }
            }
            $namespace = rtrim($namespace, '\\') . '\\' . substr($classPath, 0, $pos);
            $classPath = substr($classPath, $pos + 1);
        }
        return false;
    }