Skip to main content

clientapi_pbs/models/
admin_datastore_get_status_response_data.rs

1/*
2 * Proxmox Backup Server API
3 *
4 * Generated from apidoc.js. NOT an official Proxmox specification. See https://pbs.proxmox.com/docs/api-viewer/ for the upstream documentation.
5 *
6 * The version of the OpenAPI document: 9.x
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 AdminDatastoreGetStatusResponseData {
16
17    /// Available space (bytes).
18    #[serde(rename = "avail")]
19    pub avail: i64,
20
21    /// Datastore backend type
22    #[serde(rename = "backend-type")]
23    pub backend_type: models::PbsBackendTypeEnum,
24
25    #[serde(rename = "counts", skip_serializing_if = "Option::is_none")]
26    pub counts: Option<Box<models::AdminDatastoreGetStatusResponseDataCounts>>,
27
28    #[serde(rename = "gc-status", skip_serializing_if = "Option::is_none")]
29    pub gc_status: Option<Box<models::AdminDatastoreGetStatusResponseDataGcStatus>>,
30
31    #[serde(rename = "s3-statistics", skip_serializing_if = "Option::is_none")]
32    pub s3_statistics: Option<Box<models::AdminDatastoreGetStatusResponseDataS3Statistics>>,
33
34    /// Total space (bytes).
35    #[serde(rename = "total")]
36    pub total: i64,
37
38    /// Used space (bytes).
39    #[serde(rename = "used")]
40    pub used: i64,
41
42
43}
44
45impl AdminDatastoreGetStatusResponseData {
46    pub fn new(avail: i64, backend_type: models::PbsBackendTypeEnum, total: i64, used: i64) -> AdminDatastoreGetStatusResponseData {
47        AdminDatastoreGetStatusResponseData {
48            
49            avail,
50            
51            backend_type,
52            
53            counts: None,
54            
55            gc_status: None,
56            
57            s3_statistics: None,
58            
59            total,
60            
61            used,
62            
63        }
64    }
65}
66
67