#include "filesystem.hpp" #define WIN32_LEAN_AND_MEAN #include #undef CopyFile bool Filesystem::DirectoryExists(const std::string& path) { DWORD ftyp = GetFileAttributesA(path.c_str()); return ftyp != INVALID_FILE_ATTRIBUTES && ftyp & FILE_ATTRIBUTE_DIRECTORY; } bool Filesystem::FileExists(const std::string& path) { DWORD ftyp = GetFileAttributesA(path.c_str()); return ftyp != INVALID_FILE_ATTRIBUTES && !(ftyp & FILE_ATTRIBUTE_DIRECTORY); } std::vector Filesystem::DirectoryContents(const std::string& directory) { std::vector tmp; //TODO: implement windows directory contents listing return tmp; } void Filesystem::CopyFile(const std::string& src, const std::string& dst, bool overwrite) { //TODO: implement windows copyfile } std::string Filesystem::Canonical(const std::string& path) { //TODO: implement windows canonicallize path return path; }