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};

/// Accessory : The accessory of the artifact
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Accessory {
    /// The ID of the accessory
    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
    pub id: Option<i64>,
    /// The artifact id of the accessory
    #[serde(rename = "artifact_id", skip_serializing_if = "Option::is_none")]
    pub artifact_id: Option<i64>,
    /// Going to be deprecated, use repo and digest for insteand. The subject artifact id of the accessory.
    #[serde(rename = "subject_artifact_id", skip_serializing_if = "Option::is_none")]
    pub subject_artifact_id: Option<i64>,
    /// The subject artifact digest of the accessory
    #[serde(rename = "subject_artifact_digest", skip_serializing_if = "Option::is_none")]
    pub subject_artifact_digest: Option<String>,
    /// The subject artifact repository name of the accessory
    #[serde(rename = "subject_artifact_repo", skip_serializing_if = "Option::is_none")]
    pub subject_artifact_repo: Option<String>,
    /// The artifact size of the accessory
    #[serde(rename = "size", skip_serializing_if = "Option::is_none")]
    pub size: Option<i64>,
    /// The artifact digest of the accessory
    #[serde(rename = "digest", skip_serializing_if = "Option::is_none")]
    pub digest: Option<String>,
    /// The artifact size of the accessory
    #[serde(rename = "type", skip_serializing_if = "Option::is_none")]
    pub r#type: Option<String>,
    /// The icon of the accessory
    #[serde(rename = "icon", skip_serializing_if = "Option::is_none")]
    pub icon: Option<String>,
    /// The creation time of the accessory
    #[serde(rename = "creation_time", skip_serializing_if = "Option::is_none")]
    pub creation_time: Option<String>,
}

impl Accessory {
    /// The accessory of the artifact
    pub fn new() -> Accessory {
        Accessory {
            id: None,
            artifact_id: None,
            subject_artifact_id: None,
            subject_artifact_digest: None,
            subject_artifact_repo: None,
            size: None,
            digest: None,
            r#type: None,
            icon: None,
            creation_time: None,
        }
    }
}