pub struct ConditionalExpression {
pub condition: Box<Expression>,
pub true_part: Box<Expression>,
pub false_part: Box<Expression>,
}Expand description
condition ? true_part : false_part.
Fields§
§condition: Box<Expression>§true_part: Box<Expression>§false_part: Box<Expression>Implementations§
Source§impl ConditionalExpression
impl ConditionalExpression
pub fn new( condition: Expression, true_part: Expression, false_part: Expression, ) -> Self
pub fn evaluate( &self, context: &ExpressionEvaluationContext<'_>, ) -> ExpressionVariant
pub fn collect_references(&self, references: &mut HashSet<(String, String)>)
Trait Implementations§
Source§impl Clone for ConditionalExpression
impl Clone for ConditionalExpression
Source§impl Debug for ConditionalExpression
impl Debug for ConditionalExpression
Source§impl Display for ConditionalExpression
impl Display for ConditionalExpression
Source§impl From<ConditionalExpression> for Expression
impl From<ConditionalExpression> for Expression
Source§fn from(value: ConditionalExpression) -> Expression
fn from(value: ConditionalExpression) -> Expression
Converts to this type from the input type.
Source§impl PartialEq for ConditionalExpression
impl PartialEq for ConditionalExpression
impl StructuralPartialEq for ConditionalExpression
Auto Trait Implementations§
impl Freeze for ConditionalExpression
impl RefUnwindSafe for ConditionalExpression
impl Send for ConditionalExpression
impl Sync for ConditionalExpression
impl Unpin for ConditionalExpression
impl UnsafeUnpin for ConditionalExpression
impl UnwindSafe for ConditionalExpression
Blanket Implementations§
Source§impl<T> AnyValue for Twhere
T: PartialEq + 'static,
impl<T> AnyValue for Twhere
T: PartialEq + 'static,
fn any_value_as_any(&self) -> &(dyn Any + 'static)
fn any_value_eq(&self, other: &(dyn AnyValue + 'static)) -> bool
fn any_value_type_name(&self) -> &'static str
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
Source§impl<T> ClassDefaults for Twhere
T: ?Sized,
impl<T> ClassDefaults for Twhere
T: ?Sized,
Source§fn static_constructor()
fn static_constructor()
The static constructor of a type: work done once per thread, after
the properties of the type are registered and before its first
instance exists (class handlers,
affects_render, metadata
overrides). Read more