/*
 * Artifact Keeper API
 *
 * Enterprise artifact registry supporting 45+ package formats.
 *
 * The version of the OpenAPI document: 1.0.0-rc.3
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct UpdateRepositoryRequest {
    #[serde(rename = "description", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub description: Option<Option<String>>,
    /// Update the Cargo index upstream URL (stored in `repository_config`). When provided, upserts the `index_upstream_url` key for this repository.
    #[serde(rename = "index_upstream_url", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub index_upstream_url: Option<Option<String>>,
    #[serde(rename = "is_public", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub is_public: Option<Option<bool>>,
    #[serde(rename = "key", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub key: Option<Option<String>>,
    #[serde(rename = "name", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub name: Option<Option<String>>,
    #[serde(rename = "quota_bytes", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub quota_bytes: Option<Option<i64>>,
}

impl UpdateRepositoryRequest {
    pub fn new() -> UpdateRepositoryRequest {
        UpdateRepositoryRequest {
            description: None,
            index_upstream_url: None,
            is_public: None,
            key: None,
            name: None,
            quota_bytes: None,
        }
    }
}

