harbor_api/models/
execution.rs

1/*
2 * Harbor API
3 *
4 * These APIs provide services for manipulating Harbor project.
5 *
6 * The version of the OpenAPI document: 2.0
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct Execution {
16    /// The ID of execution
17    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
18    pub id: Option<i32>,
19    /// The vendor type of execution
20    #[serde(rename = "vendor_type", skip_serializing_if = "Option::is_none")]
21    pub vendor_type: Option<String>,
22    /// The vendor id of execution
23    #[serde(rename = "vendor_id", skip_serializing_if = "Option::is_none")]
24    pub vendor_id: Option<i32>,
25    /// The status of execution
26    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
27    pub status: Option<String>,
28    /// The status message of execution
29    #[serde(rename = "status_message", skip_serializing_if = "Option::is_none")]
30    pub status_message: Option<String>,
31    #[serde(rename = "metrics", skip_serializing_if = "Option::is_none")]
32    pub metrics: Option<Box<models::Metrics>>,
33    /// The trigger of execution
34    #[serde(rename = "trigger", skip_serializing_if = "Option::is_none")]
35    pub trigger: Option<String>,
36    #[serde(rename = "extra_attrs", skip_serializing_if = "Option::is_none")]
37    pub extra_attrs: Option<std::collections::HashMap<String, serde_json::Value>>,
38    /// The start time of execution
39    #[serde(rename = "start_time", skip_serializing_if = "Option::is_none")]
40    pub start_time: Option<String>,
41    /// The end time of execution
42    #[serde(rename = "end_time", skip_serializing_if = "Option::is_none")]
43    pub end_time: Option<String>,
44}
45
46impl Execution {
47    pub fn new() -> Execution {
48        Execution {
49            id: None,
50            vendor_type: None,
51            vendor_id: None,
52            status: None,
53            status_message: None,
54            metrics: None,
55            trigger: None,
56            extra_attrs: None,
57            start_time: None,
58            end_time: None,
59        }
60    }
61}
62