Struct huelib::resource::rule::Condition [−][src]
pub struct Condition {
pub address: String,
pub operator: ConditionOperator,
pub value: Option<String>,
}
Expand description
Condition of a rule.
Fields
address: String
Address of an attribute of a sensor resource.
operator: ConditionOperator
Operator of the condition.
value: Option<String>
Value of the condition.
The resource attribute is compared to this value using the given operator. The value is casted to the data type of the resource attribute. If the cast fails or the operator does not support the data type the value is casted to the rule is rejected.
Trait Implementations
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
Auto Trait Implementations
impl RefUnwindSafe for Condition
impl UnwindSafe for Condition
Blanket Implementations
Mutably borrows from an owned value. Read more