17 #ifndef TESSERACT_TRAINING_FILEIO_H_ 18 #define TESSERACT_TRAINING_FILEIO_H_ 33 static FILE*
OpenOrDie(
const std::string& filename,
const std::string& mode);
34 static FILE*
Open(
const std::string& filename,
const std::string& mode);
41 static bool Readable(
const std::string& filename);
48 static std::string
JoinPath(
const std::string& prefix,
const std::string& suffix);
50 static bool Delete(
const char* pathname);
66 bool Read(std::string* out);
87 void WriteString(
const std::string& str);
98 #endif // TESSERACT_TRAINING_FILEIO_H_ FILE * stream_
Definition: fileio.h:94
static void WriteStringToFileOrDie(const std::string &str, const std::string &filename)
Definition: fileio.cpp:53
static bool Delete(const char *pathname)
Definition: fileio.cpp:88
static FILE * OpenOrDie(const std::string &filename, const std::string &mode)
Definition: fileio.cpp:43
Definition: baseapi.cpp:94
static bool Readable(const std::string &filename)
Definition: fileio.cpp:64
static bool ReadFileToString(const std::string &filename, std::string *out)
Definition: fileio.cpp:73
static FILE * Open(const std::string &filename, const std::string &mode)
Definition: fileio.cpp:39
static std::string JoinPath(const std::string &prefix, const std::string &suffix)
Definition: fileio.cpp:82
static bool DeleteMatchingFiles(const char *pattern)
Definition: fileio.cpp:112