harbor-api 2.0.0

These APIs provide services for manipulating Harbor project.
Documentation
/*
 * Harbor API
 *
 * These APIs provide services for manipulating Harbor project.
 *
 * The version of the OpenAPI document: 2.0
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ProjectReq {
    /// The name of the project.
    #[serde(rename = "project_name", skip_serializing_if = "Option::is_none")]
    pub project_name: Option<String>,
    /// deprecated, reserved for project creation in replication
    #[serde(rename = "public", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub public: Option<Option<bool>>,
    #[serde(rename = "metadata", skip_serializing_if = "Option::is_none")]
    pub metadata: Option<Box<models::ProjectMetadata>>,
    #[serde(rename = "cve_allowlist", skip_serializing_if = "Option::is_none")]
    pub cve_allowlist: Option<Box<models::CveAllowlist>>,
    /// The storage quota of the project.
    #[serde(rename = "storage_limit", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub storage_limit: Option<Option<i64>>,
    /// The ID of referenced registry when creating the proxy cache project
    #[serde(rename = "registry_id", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub registry_id: Option<Option<i64>>,
}

impl ProjectReq {
    pub fn new() -> ProjectReq {
        ProjectReq {
            project_name: None,
            public: None,
            metadata: None,
            cve_allowlist: None,
            storage_limit: None,
            registry_id: None,
        }
    }
}