public function run()
    {
        $this->loader->register();
        $result   = true;
        $classMap = array_slice($this->classMap, 0);

        // Now try to autoload all classes.
        while ($classMap) {
            $file  = reset($classMap);
            $class = key($classMap);
            try {
                $result = $this->tryLoadClass($class, $file) && $result;
            } catch (ParentClassNotFoundException $exception) {
                $this->handleParentClassNotFound($exception, $classMap);

                continue;
            }

            unset($classMap[$class]);
            $this->logger->info(
                'Loaded {class}.',
                array('class' => $class, 'file' => $file)
            );
        }

        $this->loader->unregister();

        return $result;
    }