Filesystem.cpp 421 B

1234567891011121314151617181920212223242526
  1. // Copyright 2008 Dolphin Emulator Project
  2. // SPDX-License-Identifier: GPL-2.0-or-later
  3. #include "DiscIO/Filesystem.h"
  4. namespace DiscIO
  5. {
  6. FileInfo::~FileInfo() = default;
  7. u64 FileInfo::GetTotalSize() const
  8. {
  9. if (!IsDirectory())
  10. return GetSize();
  11. u64 size = 0;
  12. for (const auto& entry : *this)
  13. size += entry.GetTotalSize();
  14. return size;
  15. }
  16. FileSystem::~FileSystem() = default;
  17. } // namespace DiscIO