pub struct Resolution { /* private fields */ }Expand description
A design kept resolved: where each node of its scene came from, the files it was made from, and the files changed since it was last valid. It keeps no scene: the design’s one scene is its holder’s, which resolving it again reads and brings across by the edits it makes.
Implementations§
Source§impl Resolution
impl Resolution
Sourcepub fn new(
files: &dyn Files,
path: &str,
) -> Result<(Resolution, Scene), Vec<Problem>>
pub fn new( files: &dyn Files, path: &str, ) -> Result<(Resolution, Scene), Vec<Problem>>
The design at path resolved — what to resolve it again from, and
its scene, for a holder to keep — or every problem it has.
Sourcepub fn files(&self) -> &[String]
pub fn files(&self) -> &[String]
The files the design’s scene is made from: the design, its imports, images, themes and fonts.
Sourcepub fn wholes(&self) -> usize
pub fn wholes(&self) -> usize
How many times the scene was brought across whole since it was first resolved: by a comparison with a fresh resolve, where resolving parts of it again couldn’t.
Sourcepub fn update(
&mut self,
held: &mut dyn Holder,
files: &dyn Files,
changed: &[String],
) -> Outcome
pub fn update( &mut self, held: &mut dyn Holder, files: &dyn Files, changed: &[String], ) -> Outcome
The design after the files changed — as the store names them, a
folder’s listing by its path and a / — changed: what they reach
resolved again against the scene held holds — the design’s last
valid one — and the edits that bring it across applied to it there,
once; or every problem the design now has, held left as it was. A
change while the design has problems is kept, and the change that
makes it valid again brings the scene across all of them.