pub struct ColumnRef { /* private fields */ }Expand description
Column identity in the native expression IR.
name is the physical/logical field name used to resolve the column against
an input schema. qualifier disambiguates which input namespace owns that
field when a node has more than one input. display_name is deliberately
separate: it is the externally visible or projected name used for output
contracts and selected diagnostics, and it may differ from name when the
same source column is projected under a distinct alias. Display
formatting uses the qualifier and lookup name.
Implementations§
Source§impl ColumnRef
impl ColumnRef
Sourcepub fn unqualified(name: impl Into<String>) -> Self
pub fn unqualified(name: impl Into<String>) -> Self
Build a column reference with no namespace qualifier.
Unqualified references resolve against the current single-input schema. The display name is initialized to the same value as the lookup name.
Sourcepub fn input(
input: usize,
name: impl Into<String>,
display_name: impl Into<String>,
) -> Self
pub fn input( input: usize, name: impl Into<String>, display_name: impl Into<String>, ) -> Self
Build a column reference scoped to an input ordinal.
This is the preferred qualifier for binary-input nodes such as joins.
input is zero-based and identifies the node input. It does not index fields.
Equality and hashing include the qualifier and both names, so a join
key spelled with a different display_name is a different key.
Sourcepub fn qualifier(&self) -> Option<&ColumnQualifier>
pub fn qualifier(&self) -> Option<&ColumnQualifier>
Input identity, or None when the column is unqualified.
Sourcepub fn display_name(&self) -> &str
pub fn display_name(&self) -> &str
Frontend spelling retained for diagnostics and expression identity.
Sourcepub fn is_qualified(&self) -> bool
pub fn is_qualified(&self) -> bool
Whether this reference names an explicit input ordinal.