antimatter_api 2.0.13

Interact with the Antimatter Cloud API
Documentation
/*
 * Antimatter Public API
 *
 * Interact with the Antimatter Cloud API
 *
 * The version of the OpenAPI document: 2.0.13
 * Contact: support@antimatter.io
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ReadContextRuleFactsInner {
    /// whether this assertion matches when the fact exists or does not exist
    #[serde(rename = "operator", skip_serializing_if = "Option::is_none")]
    pub operator: Option<Operator>,
    /// the name of the fact
    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    #[serde(rename = "arguments", skip_serializing_if = "Option::is_none")]
    pub arguments: Option<Vec<models::ReadContextRuleFactsInnerArgumentsInner>>,
}

impl ReadContextRuleFactsInner {
    pub fn new() -> ReadContextRuleFactsInner {
        ReadContextRuleFactsInner {
            operator: None,
            name: None,
            arguments: None,
        }
    }
}
/// whether this assertion matches when the fact exists or does not exist
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Operator {
    #[serde(rename = "Exists")]
    Exists,
    #[serde(rename = "NotExists")]
    NotExists,
}

impl Default for Operator {
    fn default() -> Operator {
        Self::Exists
    }
}