Add partition space information to File class

Add File::totalSpaceImpl(), File::usableSpaceImpl() and File::freeSpaceImpl() to retrieve total, available and usable space in the filesystem for the specified path.
This commit is contained in:
Tobias Taschner
2016-01-21 23:55:43 +01:00
committed by Tobias Taschner
parent 59b5b4e46e
commit 9972496811
16 changed files with 290 additions and 0 deletions

View File

@@ -316,6 +316,24 @@ void File::list(std::vector<std::string>& files) const
}
File::FileSize File::totalSpace() const
{
return totalSpaceImpl();
}
File::FileSize File::usableSpace() const
{
return usableSpaceImpl();
}
File::FileSize File::freeSpace() const
{
return freeSpaceImpl();
}
void File::list(std::vector<File>& files) const
{
files.clear();