pub enum ExprValue {
Literal(Literal),
Expr(Expression),
Interpolated(Vec<StringPart>),
Object(HashMap<String, ExprValue>),
Array(Vec<ExprValue>),
}Expand description
A value that may contain deferred expressions (parsed, not yet evaluated).
This is the bridge between the resolver and runtime: the resolver parses
all ${...} patterns into structured expressions, and the runtime evaluates
them without any string parsing.
Variants§
Literal(Literal)
Fully resolved literal (no expressions)
Expr(Expression)
Single expression (entire value is one expression)
Interpolated(Vec<StringPart>)
String with embedded expressions: "Hash: ${artifact.x | sha256}"
Object(HashMap<String, ExprValue>)
Structured object with potentially deferred fields
Array(Vec<ExprValue>)
Array of values
Implementations§
Source§impl ExprValue
impl ExprValue
Sourcepub fn as_literal_string(&self) -> Option<&str>
pub fn as_literal_string(&self) -> Option<&str>
Get the value as a literal string, if it is one.
Sourcepub fn to_display_string(&self) -> String
pub fn to_display_string(&self) -> String
Convert to a display string (for script generation, not evaluation).
For literals, returns the literal value.
For expressions, returns the expression syntax like "${artifact.ksr | sha256}".
Trait Implementations§
impl StructuralPartialEq for ExprValue
Auto Trait Implementations§
impl Freeze for ExprValue
impl RefUnwindSafe for ExprValue
impl Send for ExprValue
impl Sync for ExprValue
impl Unpin for ExprValue
impl UnsafeUnpin for ExprValue
impl UnwindSafe for ExprValue
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