// Code generated by oagen. DO NOT EDIT.

#[allow(unused_imports)]
use super::*;
#[allow(unused_imports)]
use crate::enums::*;
use serde::{Deserialize, Serialize};
/// Intersection-over-Union for split page assignments.
/// `expected` uses the split payload shape:
/// `{"splits": [{"name", "pages"}]}`
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct SplitIouCondition {
    /// Defaults to `split_iou_gte`.
    #[serde(skip_serializing_if = "Option::is_none", default)]
    pub kind: Option<String>,
    pub expected: std::collections::HashMap<String, serde_json::Value>,
    /// Defaults to `1`.
    #[serde(skip_serializing_if = "Option::is_none", default)]
    pub threshold: Option<f64>,
}
impl SplitIouCondition {
    /// Construct a new `SplitIouCondition` with the required fields set.
    #[allow(deprecated)]
    pub fn new(expected: std::collections::HashMap<String, serde_json::Value>) -> Self {
        Self {
            kind: Default::default(),
            expected,
            threshold: Default::default(),
        }
    }
}
