openapi-azure-storage-blob 0.1.1

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
Documentation
/*
 * Azure Storage Blob service
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 2026-02-06
 *
 * Generated by: https://openapi-generator.tech
 */

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

/// RetentionPolicy : The retention policy.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct RetentionPolicy {
    /// Whether to enable the retention policy.
    #[serde(rename = "Enabled")]
    pub enabled: bool,
    /// The number of days to retain the logs.
    #[serde(rename = "Days", skip_serializing_if = "Option::is_none")]
    pub days: Option<i32>,
    /// Whether to allow permanent delete.
    #[serde(
        rename = "AllowPermanentDelete",
        skip_serializing_if = "Option::is_none"
    )]
    pub allow_permanent_delete: Option<bool>,
}

impl RetentionPolicy {
    /// The retention policy.
    pub fn new(enabled: bool) -> RetentionPolicy {
        RetentionPolicy {
            enabled,
            days: None,
            allow_permanent_delete: None,
        }
    }
}