Skip to main content

land

Function land 

Source
pub fn land(
    target: &Utf8Path,
    candidate: &Candidate,
    recorded: &Recorded,
) -> Result<Outcome, AppError>
Expand description

Write the candidate into the target, and record it last.

The caller holds the target lock for the whole of this, including the observation it passes in: a candidate rendered before the lock would describe a target somebody else could still be changing.

ยงErrors

AppError::Refused where a destination escapes the target or holds bytes no record accounts for, AppError::Busy where another process holds the target, and I/O errors of the writes themselves.