Definition at line 171 of file file_system.cpp.
171 {
172 FileHandlePtr file =
openRead(path);
173 if (!file) {
175 return false;
176 }
177 fl::size size = file->size();
179 bool wrote = false;
180 while (file->available()) {
182 fl::size n = file->read(buf, sizeof(buf));
183
184 out->
append((
const char *)buf, n);
185 wrote = true;
186 }
187 file->close();
188 FASTLED_DBG_IF(!wrote,
"Failed to write any data to the output string.");
189 return wrote;
190}
FileHandlePtr openRead(const char *path)
void reserve(fl::size newCapacity)
string & append(const BitsetFixed< N > &bs)
#define FASTLED_DBG_IF(COND, MSG)
References fl::string::append(), FASTLED_DBG_IF, FASTLED_WARN, openRead(), fl::StrN< SIZE >::reserve(), and fl::StrN< SIZE >::size().
Referenced by readJson(), readScreenMap(), and readScreenMaps().