public function Check($value)
    {
        $this->error = '';
        if ($this->currentFile && $value == $this->currentFile)
        {
            return true;
        }
        if (!Folder::Exists($this->folder))
        {
            return true;
        }
        $files = Folder::GetFiles($this->folder);
        if ($this->fileExtension)
        {
            $value = Path::AddExtension($value, $this->fileExtension);
        }
        if (in_array($value, $files))
        {
            $this->error = self::ExistsInFolder;
        }
        return $this->error == '';
    }