Added Directory::Exists

Former-commit-id: 51e6b909b323074401b0200747db35f2e4b1c42a
This commit is contained in:
Lynix 2013-08-03 20:20:30 +02:00
parent f47ecfe414
commit 19e02a900b
2 changed files with 12 additions and 0 deletions

View File

@ -36,6 +36,8 @@ class NAZARA_API NzDirectory
void Close();
bool Exists() const;
NzString GetPattern() const;
NzString GetResultName() const;
NzString GetResultPath() const;

View File

@ -51,6 +51,16 @@ void NzDirectory::Close()
}
}
bool NzDirectory::Exists() const
{
NazaraLock(m_mutex);
if (IsOpen())
return true; // Le fichier est ouvert, donc il existe
else
return Exists(m_dirPath);
}
NzString NzDirectory::GetPattern() const
{
NazaraLock(m_mutex);