pub struct BinaryOp {
    pub lhs_expr: Expression,
    pub operator: BinaryOperator,
    pub rhs_expr: Expression,
}Expand description
An operation that applies an operator to two expressions.
Fields§
§lhs_expr: ExpressionThe expression on the left-hand-side of the operation.
operator: BinaryOperatorThe binary operator to use on the expressions.
rhs_expr: ExpressionThe expression on the right-hand-side of the operation.
Implementations§
source§impl BinaryOp
 
impl BinaryOp
sourcepub fn new<L, R>(lhs_expr: L, operator: BinaryOperator, rhs_expr: R) -> BinaryOpwhere
    L: Into<Expression>,
    R: Into<Expression>,
 
pub fn new<L, R>(lhs_expr: L, operator: BinaryOperator, rhs_expr: R) -> BinaryOpwhere L: Into<Expression>, R: Into<Expression>,
Creates a new BinaryOp from two expressions and an operator.
Trait Implementations§
source§impl<'de> Deserialize<'de> for BinaryOp
 
impl<'de> Deserialize<'de> for BinaryOp
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
    __D: Deserializer<'de>,
 
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Format for BinaryOp
 
impl Format for BinaryOp
source§fn format<W>(&self, fmt: &mut Formatter<'_, W>) -> Result<()>where
    W: Write,
 
fn format<W>(&self, fmt: &mut Formatter<'_, W>) -> Result<()>where W: Write,
Formats a HCL structure using a formatter and writes the result to the provided writer. Read more
source§impl From<BinaryOp> for Expression
 
impl From<BinaryOp> for Expression
source§impl<'de> IntoDeserializer<'de, Error> for BinaryOp
 
impl<'de> IntoDeserializer<'de, Error> for BinaryOp
§type Deserializer = MapAccessDeserializer<BinaryOpAccess>
 
type Deserializer = MapAccessDeserializer<BinaryOpAccess>
The type of the deserializer being converted into.
source§fn into_deserializer(self) -> Self::Deserializer
 
fn into_deserializer(self) -> Self::Deserializer
Convert this value into a deserializer.
source§impl PartialEq<BinaryOp> for BinaryOp
 
impl PartialEq<BinaryOp> for BinaryOp
impl Eq for BinaryOp
impl StructuralEq for BinaryOp
impl StructuralPartialEq for BinaryOp
Auto Trait Implementations§
impl RefUnwindSafe for BinaryOp
impl Send for BinaryOp
impl Sync for BinaryOp
impl Unpin for BinaryOp
impl UnwindSafe for BinaryOp
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
    Q: Eq + ?Sized,
    K: Borrow<Q> + ?Sized,
 
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
 
fn equivalent(&self, key: &K) -> bool
Compare self to 
key and return true if they are equal.