pub enum CellSource {
Empty,
Literal(Value),
Template {
text: String,
num_fmt: NumFmtKind,
format_code: Option<String>,
style_idx: Option<usize>,
},
Subtotal {
aggregate: String,
field: String,
},
CellFormula {
text: String,
cached: Value,
format_code: Option<String>,
style_idx: Option<usize>,
},
}Variants§
Empty
Literal(Value)
Template
Contains at least one {{ ... }} expression block. num_fmt
is the classified numFmt of the underlying template cell,
used by ADR-0003 single-expression coercion at render time.
format_code is the raw numFmt string from the template (e.g.
"0.00" or "yyyy-mm-dd") — preserved so the output writer
can emit the same display format on the rendered cell.
style_idx is the index into the host-supplied
StyleManifest::styles table, populated when the renderer
receives a manifest (Phase 2 Task 2.2). None when the host
didn’t ship a manifest or the template cell wasn’t styled.
Subtotal
{{ @subtotal <FN>(<ColumnRef>) }} — emitted at the end of
each group when the enclosing block has a @group directive.
aggregate is normalised to uppercase; field is the bare
column name (Phase-1 scope: no Source[Field] form).
CellFormula
A native Excel formula in a template cell. ADR-0021 (static
cell) and ADR-0046 (cell inside an expansion block): the
formula text is preserved verbatim — references are NOT
adjusted to match the cloned row’s position. The cached
value is what calamine read from the template, used by Stage
1 conformance comparison and by Excel until it recalculates.
Implementations§
Source§impl CellSource
impl CellSource
pub fn is_template(&self) -> bool
Trait Implementations§
Source§impl Clone for CellSource
impl Clone for CellSource
Source§fn clone(&self) -> CellSource
fn clone(&self) -> CellSource
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more