Skip to main content

tapis_workflows/models/
base_archive.rs

1/*
2 * Tapis Workflows API
3 *
4 * Create and manage pipelines
5 *
6 * The version of the OpenAPI document: 1.6.0
7 * Contact: cicsupport@tacc.utexas.edu
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 BaseArchive {
16    #[serde(rename = "id")]
17    pub id: String,
18    #[serde(rename = "type")]
19    pub r#type: models::EnumArchiveType,
20    #[serde(rename = "group")]
21    pub group: uuid::Uuid,
22    #[serde(rename = "tenant_id")]
23    pub tenant_id: String,
24    #[serde(rename = "owner")]
25    pub owner: String,
26    #[serde(rename = "uuid", skip_serializing_if = "Option::is_none")]
27    pub uuid: Option<uuid::Uuid>,
28    #[serde(rename = "archive_dir")]
29    pub archive_dir: String,
30}
31
32impl BaseArchive {
33    pub fn new(
34        id: String,
35        r#type: models::EnumArchiveType,
36        group: uuid::Uuid,
37        tenant_id: String,
38        owner: String,
39        archive_dir: String,
40    ) -> BaseArchive {
41        BaseArchive {
42            id,
43            r#type,
44            group,
45            tenant_id,
46            owner,
47            uuid: None,
48            archive_dir,
49        }
50    }
51}