windmill-api 1.684.1

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
Documentation
/*
 * Windmill API
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.684.1
 * Contact: contact@windmill.dev
 * Generated by: https://openapi-generator.tech
 */

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

/// WhileloopFlow : Executes nested modules repeatedly while a condition is true. The loop checks the condition after each iteration. Use stop_after_if on modules to control loop termination
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct WhileloopFlow {
    /// Steps to execute in each iteration. Use stop_after_if to control when the loop ends
    #[serde(rename = "modules")]
    pub modules: Vec<models::FlowModule>,
    /// If true, iteration failures don't stop the loop. Failed iterations return null
    #[serde(rename = "skip_failures")]
    pub skip_failures: bool,
    #[serde(rename = "type")]
    pub r#type: Type,
    /// If true, iterations run concurrently (use with caution in while loops)
    #[serde(rename = "parallel", skip_serializing_if = "Option::is_none")]
    pub parallel: Option<bool>,
    #[serde(rename = "parallelism", skip_serializing_if = "Option::is_none")]
    pub parallelism: Option<Box<models::InputTransform>>,
    #[serde(rename = "squash", skip_serializing_if = "Option::is_none")]
    pub squash: Option<bool>,
}

impl WhileloopFlow {
    /// Executes nested modules repeatedly while a condition is true. The loop checks the condition after each iteration. Use stop_after_if on modules to control loop termination
    pub fn new(modules: Vec<models::FlowModule>, skip_failures: bool, r#type: Type) -> WhileloopFlow {
        WhileloopFlow {
            modules,
            skip_failures,
            r#type,
            parallel: None,
            parallelism: None,
            squash: None,
        }
    }
}
/// 
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Type {
    #[serde(rename = "whileloopflow")]
    Whileloopflow,
}

impl Default for Type {
    fn default() -> Type {
        Self::Whileloopflow
    }
}