finish
Combination of flush followed by renameIntoPlace.
Function parameters
Parameters
- af:*AtomicFile
Note that the `Dir.atomicFile` API may be more handy than this lower-level function.
Functions
- init
- Note that the `Dir.atomicFile` API may be more handy than this lower-level function.
- deinit
- Always call deinit, even after a successful finish().
- renameIntoPlace
- On Windows, this function introduces a period of time where some file
- finish
- Combination of `flush` followed by `renameIntoPlace`.
Error sets in this namespace
Error Sets
Source
Implementation
pub fn finish(af: *AtomicFile) FinishError!void {
try af.flush();
try af.renameIntoPlace();
}