chore: io/FileSystem remove unused methods
This commit is contained in:
@ -7,34 +7,8 @@
|
||||
|
||||
#include "Filesystem.h"
|
||||
|
||||
#include <fstream>
|
||||
|
||||
namespace deskflow {
|
||||
|
||||
namespace {
|
||||
|
||||
template <class Stream> void openUtf8PathImpl(Stream &stream, const fs::path &path, std::ios_base::openmode mode)
|
||||
{
|
||||
stream.open(path.native().c_str(), mode);
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
void openUtf8Path(std::ifstream &stream, const fs::path &path, std::ios_base::openmode mode)
|
||||
{
|
||||
openUtf8PathImpl(stream, path, mode);
|
||||
}
|
||||
|
||||
void openUtf8Path(std::ofstream &stream, const fs::path &path, std::ios_base::openmode mode)
|
||||
{
|
||||
openUtf8PathImpl(stream, path, mode);
|
||||
}
|
||||
|
||||
void openUtf8Path(std::fstream &stream, const fs::path &path, std::ios_base::openmode mode)
|
||||
{
|
||||
openUtf8PathImpl(stream, path, mode);
|
||||
}
|
||||
|
||||
std::FILE *fopenUtf8Path(const fs::path &path, const std::string &mode)
|
||||
{
|
||||
#if SYSAPI_WIN32
|
||||
|
||||
@ -9,19 +9,11 @@
|
||||
|
||||
#include <cstdio>
|
||||
#include <filesystem>
|
||||
#include <ios>
|
||||
#include <iosfwd>
|
||||
|
||||
namespace deskflow {
|
||||
|
||||
namespace fs = std::filesystem;
|
||||
|
||||
void openUtf8Path(std::ifstream &stream, const fs::path &path, std::ios_base::openmode mode = std::ios_base::in);
|
||||
void openUtf8Path(std::ofstream &stream, const fs::path &path, std::ios_base::openmode mode = std::ios_base::out);
|
||||
void openUtf8Path(
|
||||
std::fstream &stream, const fs::path &path, std::ios_base::openmode mode = std::ios_base::in | std::ios_base::out
|
||||
);
|
||||
|
||||
std::FILE *fopenUtf8Path(const fs::path &path, const std::string &mode);
|
||||
|
||||
} // namespace deskflow
|
||||
|
||||
Reference in New Issue
Block a user