Sheet handle
Sheet handle · Type
Open-workbook handle returned by mash.sheet.open(file).
Writes accumulate in PHP; every read or save is ONE bridge run carrying all pending ops (batch shape: do your set() calls first, then read or save). Reads always recalculate through the engine, so a get() after set() returns the recomputed value; formulas outside the engine’s tier keep the file’s cached value (flagged() counts them).
Methods
Section titled “Methods”flagged
Section titled “flagged”sheet.flagged() → int
Formulas the engine could not recalculate on the last run.
sheet.get(ref: string)
Read one cell (recalculated; pending set() values included).
recalc
Section titled “recalc”sheet.recalc() → int
Recalculate now; returns the count of formulas kept at cached values.
sheet.save(folder: File, name?: string, overwrite?: bool = true) → Document
Save the filled workbook into a folder (share root or subfolder object), e.g. book.save(root, "Reports/Filled.xlsx"). Untouched parts stay byte-identical; recalculated cells carry fresh caches.
sheet.set(ref: string, value?: mixed) → Handle
Write a value into a cell: number, boolean, text, “=formula”, or null/"" to clear. Returns the handle for chaining.
sheet.sheet(name?: string) → Handle
Target a sheet by name for subsequent set/get calls (default: first sheet).
sheetNames
Section titled “sheetNames”sheet.sheetNames() → array
Sheet names in workbook order.
values
Section titled “values”sheet.values(range: string) → array
Read a range like “A1:C10” as an array of row arrays.