hanzo-client 8.5.156

Generated client for the Hanzo API — every service, one crate.
Documentation
/*
 * Hanzo Cloud API
 *
 * The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
 *
 * The version of the OpenAPI document: v1
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct RiskLineage {
    /// Dataset is the dataset traced.
    #[serde(rename = "dataset", skip_serializing_if = "Option::is_none")]
    pub dataset: Option<String>,
    /// Digest is the version's fingerprint, repeated here so a lineage answer is self-contained.
    #[serde(rename = "digest", skip_serializing_if = "Option::is_none")]
    pub digest: Option<String>,
    /// From is where the window actually read opens, RFC 3339. Same as the spec's.
    #[serde(rename = "from", skip_serializing_if = "Option::is_none")]
    pub from: Option<String>,
    /// Holds is what the source holds for the same window NOW. The difference between it and Rows is the whole of the reproducibility claim.
    #[serde(rename = "holds", skip_serializing_if = "Option::is_none")]
    pub holds: Option<i32>,
    /// Oversize is how many subjects the window held that were too large to represent when this version was built. It is part of the fingerprint, so it is part of what \"reproducible\" is measured over.
    #[serde(rename = "oversize", skip_serializing_if = "Option::is_none")]
    pub oversize: Option<i32>,
    /// Refusal says which way it failed — the window expired, or the source now holds a different count. Absent when Reproducible is true.
    #[serde(rename = "refusal", skip_serializing_if = "Option::is_none")]
    pub refusal: Option<String>,
    /// Reproducible is true when the source still holds what this version was built from — measured by asking it again, not recalled. False is ordinary: the source is fed by a rollup that runs behind the events, so \"it holds more now\" is the common case and it means re-running the spec would not produce this version.
    #[serde(rename = "reproducible", skip_serializing_if = "Option::is_none")]
    pub reproducible: Option<bool>,
    /// Retention is the source's own expiry rule as the store reports it, read at materialisation time rather than assumed. A source whose retention is shorter than this window cannot re-derive it.
    #[serde(rename = "retention", skip_serializing_if = "Option::is_none")]
    pub retention: Option<String>,
    /// Rows is how many rows the source held for that window at materialisation time. Holds is the same question asked now, and the difference between them is the whole of the reproducibility claim.
    #[serde(rename = "rows", skip_serializing_if = "Option::is_none")]
    pub rows: Option<i32>,
    /// Share is the fraction of subjects admitted, in thousandths.
    #[serde(rename = "share", skip_serializing_if = "Option::is_none")]
    pub share: Option<i32>,
    /// Source is the plane the rows were derived from.
    #[serde(rename = "source", skip_serializing_if = "Option::is_none")]
    pub source: Option<String>,
    /// Subjects is how many distinct subjects those rows belonged to. It is the real sample size — the row count flatters it whenever a subject is active.
    #[serde(rename = "subjects", skip_serializing_if = "Option::is_none")]
    pub subjects: Option<i32>,
    /// To is where it ends: the spec's own end pulled BACK by the maturity horizon, so it is usually earlier than the spec says. This is the window a reproduction has to ask for — asking the spec's would not return these rows.
    #[serde(rename = "to", skip_serializing_if = "Option::is_none")]
    pub to: Option<String>,
    /// Version is the version traced — the one asked for, or the newest published one when the request named none.
    #[serde(rename = "version", skip_serializing_if = "Option::is_none")]
    pub version: Option<i32>,
}

impl RiskLineage {
    pub fn new() -> RiskLineage {
        RiskLineage {
            dataset: None,
            digest: None,
            from: None,
            holds: None,
            oversize: None,
            refusal: None,
            reproducible: None,
            retention: None,
            rows: None,
            share: None,
            source: None,
            subjects: None,
            to: None,
            version: None,
        }
    }
}