public function current()
    {
        $fileInfo = parent::current();
        if ($fileInfo->isDir()) {
            return new Folder(array('name' => $fileInfo->getRealPath()));
        }
        return new File($fileInfo->getRealPath());
    }