Skip to main content

restore

Function restore 

Source
pub fn restore(
    saved: &State,
    registry: &FrameRegistry,
    valid: &dyn Fn(&FrameId, &Value) -> Option<String>,
) -> (State, Vec<Dropped>)
Expand description

Brings a saved state back against today’s frames: a place that is unknown, transient or refused by valid (its payload no longer exists) cuts the path there (its children go with it); a mode is dropped alone (a pushed one gives its place back to what it replaced). Restoring never fails; the revision is kept.