Skip to main content

clientapi_pbs/models/
config_traffic_control_update_traffic_control_request.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 ConfigTrafficControlUpdateTrafficControlRequest {
16
17    /// Byte size with optional unit (B, KB (base 10), MB, GB, ..., KiB (base 2), MiB, Gib, ...).
18    #[serde(rename = "burst-in", skip_serializing_if = "Option::is_none")]
19    pub burst_in: Option<String>,
20
21    /// Byte size with optional unit (B, KB (base 10), MB, GB, ..., KiB (base 2), MiB, Gib, ...).
22    #[serde(rename = "burst-out", skip_serializing_if = "Option::is_none")]
23    pub burst_out: Option<String>,
24
25    /// Comment.
26    #[serde(rename = "comment", skip_serializing_if = "Option::is_none")]
27    pub comment: Option<String>,
28
29    /// List of properties to delete.
30    #[serde(rename = "delete", skip_serializing_if = "Option::is_none")]
31    pub delete: Option<Vec<models::PbsConfigTrafficControlInlineEnum>>,
32
33    /// Prevent changes if current configuration file has different SHA256 digest. This can be used to prevent concurrent modifications.
34    #[serde(rename = "digest", skip_serializing_if = "Option::is_none")]
35    pub digest: Option<String>,
36
37    /// Rule applies to Source IPs within this networks
38    #[serde(rename = "network", skip_serializing_if = "Option::is_none")]
39    pub network: Option<Vec<String>>,
40
41    /// Byte size with optional unit (B, KB (base 10), MB, GB, ..., KiB (base 2), MiB, Gib, ...).
42    #[serde(rename = "rate-in", skip_serializing_if = "Option::is_none")]
43    pub rate_in: Option<String>,
44
45    /// Byte size with optional unit (B, KB (base 10), MB, GB, ..., KiB (base 2), MiB, Gib, ...).
46    #[serde(rename = "rate-out", skip_serializing_if = "Option::is_none")]
47    pub rate_out: Option<String>,
48
49    /// Enable the rule at specific times
50    #[serde(rename = "timeframe", skip_serializing_if = "Option::is_none")]
51    pub timeframe: Option<Vec<String>>,
52
53    /// Rule applies to authenticated API requests of any of these users (overrides IP-only rules)
54    #[serde(rename = "users", skip_serializing_if = "Option::is_none")]
55    pub users: Option<Vec<String>>,
56
57
58}
59
60impl ConfigTrafficControlUpdateTrafficControlRequest {
61    pub fn new() -> ConfigTrafficControlUpdateTrafficControlRequest {
62        ConfigTrafficControlUpdateTrafficControlRequest {
63            
64            burst_in: None,
65            
66            burst_out: None,
67            
68            comment: None,
69            
70            delete: None,
71            
72            digest: None,
73            
74            network: None,
75            
76            rate_in: None,
77            
78            rate_out: None,
79            
80            timeframe: None,
81            
82            users: None,
83            
84        }
85    }
86}
87
88