pub struct Calc {
pub graph: Graph,
pub fixed_now: Option<f64>,
pub circular: Vec<Key>,
pub last_recalc_cells: usize,
/* private fields */
}Expand description
Calculation state kept beside a workbook.
Fields§
§graph: Graph§fixed_now: Option<f64>Fixed “now” for deterministic tests; None = system clock.
circular: Vec<Key>Cells whose formulas have errors from cycles.
last_recalc_cells: usizeImplementations§
Source§impl Calc
impl Calc
pub fn new() -> Self
Sourcepub fn recalc_all(&mut self, wb: &mut Workbook)
pub fn recalc_all(&mut self, wb: &mut Workbook)
Recalculates every formula (F9 / Ctrl+Alt+F9, and after loading).
Sourcepub fn cells_changed(&mut self, wb: &mut Workbook, changed: &[Key])
pub fn cells_changed(&mut self, wb: &mut Workbook, changed: &[Key])
Updates the graph for cells whose content changed and recalculates what depends on them.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Calc
impl RefUnwindSafe for Calc
impl Send for Calc
impl Sync for Calc
impl Unpin for Calc
impl UnsafeUnpin for Calc
impl UnwindSafe for Calc
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more