omni::extras::readFile
Defined in omni/extras/FileSystemHelpers.h
- 
inline std::pair<bool, std::string> omni::extras::readFile(const char *path)
- Reads file content into a string. - Warning - This function reads data in a binary fashion and stores it in a - std::string. As such, the string may contain non-printable characters or even- NULcharacters. No conversion of Windows line endings is performed.- Parameters
- path – The path to read 
- Returns
- a - std::pair, where the- firstmember indicates success if- trueand the- secondmember is the contents; if- firstis- falsethen- secondwill always be empty. If the file is valid but empty,- firstwill be- truebut- secondwill be empty.