| 300 | Status Flush() override { return FlushBuffer(); } |
| 301 | |
| 302 | Status Sync() override { |
| 303 | // On Windows no need to sync parent directory. Its metadata will be updated |
| 304 | // via the creation of the new file, without an explicit sync. |
| 305 | |
| 306 | Status status = FlushBuffer(); |
| 307 | if (!status.ok()) { |
| 308 | return status; |
| 309 | } |
| 310 | |
| 311 | if (!::FlushFileBuffers(handle_.get())) { |
| 312 | return Status::IOError(filename_, |
| 313 | GetWindowsErrorMessage(::GetLastError())); |
| 314 | } |
| 315 | return Status::OK(); |
| 316 | } |
| 317 | |
| 318 | std::string GetName() const override { return filename_; } |
| 319 |
nothing calls this directly
no test coverage detected