tapis-files 0.3.0

The Tapis Files API provides for management of file resources on Tapis systems
Documentation
/*
 * Tapis Files API
 *
 * The Tapis Files API provides for management of file resources on Tapis systems
 *
 * The version of the OpenAPI document: 1.8.2
 * Contact: cicsupport@tacc.utexas.edu
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct PostIt {
    /// The unique ID of the PostIt.
    #[serde(rename = "postitId", skip_serializing_if = "Option::is_none")]
    pub postit_id: Option<uuid::Uuid>,
    /// The ID of the system where the file pointed to by the PostIt resides.
    #[serde(rename = "systemId", skip_serializing_if = "Option::is_none")]
    pub system_id: Option<String>,
    /// The owner of the PostIt.
    #[serde(rename = "owner", skip_serializing_if = "Option::is_none")]
    pub owner: Option<String>,
    /// the tenant that tthe PostIt belongs to.
    #[serde(rename = "tenantId", skip_serializing_if = "Option::is_none")]
    pub tenant_id: Option<String>,
    /// Path relative to the system *rootDir*
    #[serde(rename = "path", skip_serializing_if = "Option::is_none")]
    pub path: Option<String>,
    /// The number of times the PostIt may be redeemed.  This number minus *uses* is the number of uses remaining.
    #[serde(rename = "allowedUses", skip_serializing_if = "Option::is_none")]
    pub allowed_uses: Option<i32>,
    /// The number of times the PostIt has already been retrieved.
    #[serde(rename = "timesUsed", skip_serializing_if = "Option::is_none")]
    pub times_used: Option<i32>,
    /// Authenticated user from the JWT (may be different than OBO user).
    #[serde(rename = "jwtUser", skip_serializing_if = "Option::is_none")]
    pub jwt_user: Option<String>,
    /// Tenant of authenticated user from the JWT (may be different than OBO user's tenant).
    #[serde(rename = "jwtTenantId", skip_serializing_if = "Option::is_none")]
    pub jwt_tenant_id: Option<String>,
    /// The url to use to retrieve the file pointed to by the PostIt.
    #[serde(rename = "redeemUrl", skip_serializing_if = "Option::is_none")]
    pub redeem_url: Option<String>,
    /// The expiration date/time of the PostIt.
    #[serde(rename = "expiration", skip_serializing_if = "Option::is_none")]
    pub expiration: Option<String>,
    /// Creation timestamp in UTC
    #[serde(rename = "created", skip_serializing_if = "Option::is_none")]
    pub created: Option<String>,
    /// Last update timestamp in UTC
    #[serde(rename = "updated", skip_serializing_if = "Option::is_none")]
    pub updated: Option<String>,
}

impl PostIt {
    pub fn new() -> PostIt {
        PostIt {
            postit_id: None,
            system_id: None,
            owner: None,
            tenant_id: None,
            path: None,
            allowed_uses: None,
            times_used: None,
            jwt_user: None,
            jwt_tenant_id: None,
            redeem_url: None,
            expiration: None,
            created: None,
            updated: None,
        }
    }
}