Skip to main content

clientapi_pve/models/
lxc_move_volume_request.rs

1/*
2 * Proxmox Virtual Environment API
3 *
4 * Generated from apidoc.js. NOT an official Proxmox specification. See https://pve.proxmox.com/pve-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 LxcMoveVolumeRequest {
16
17    /// Override I/O bandwidth limit (in KiB/s).
18    #[serde(rename = "bwlimit", skip_serializing_if = "Option::is_none")]
19    pub bwlimit: Option<f64>,
20
21    /// Delete the original volume after successful copy. By default the original is kept as an unused volume entry.
22    #[serde(rename = "delete", skip_serializing_if = "Option::is_none")]
23    pub delete: Option<models::PveBoolean>,
24
25    /// Prevent changes if current configuration file has different SHA1 \" .       \"digest. This can be used to prevent concurrent modifications.
26    #[serde(rename = "digest", skip_serializing_if = "Option::is_none")]
27    pub digest: Option<String>,
28
29    /// Target Storage.
30    #[serde(rename = "storage", skip_serializing_if = "Option::is_none")]
31    pub storage: Option<String>,
32
33    /// Prevent changes if current configuration file of the target \" .       \"container has a different SHA1 digest. This can be used to prevent \" .       \"concurrent modifications.
34    #[serde(rename = "target-digest", skip_serializing_if = "Option::is_none")]
35    pub target_digest: Option<String>,
36
37    /// The (unique) ID of the VM.
38    #[serde(rename = "target-vmid", skip_serializing_if = "Option::is_none")]
39    pub target_vmid: Option<i32>,
40
41    /// The config key the volume will be moved to. Default is the source volume key.
42    #[serde(rename = "target-volume", skip_serializing_if = "Option::is_none")]
43    pub target_volume: Option<models::PveTargetVolumeEnum>,
44
45    /// Volume which will be moved.
46    #[serde(rename = "volume")]
47    pub volume: models::PveTargetVolumeEnum,
48
49
50}
51
52impl LxcMoveVolumeRequest {
53    pub fn new(volume: models::PveTargetVolumeEnum) -> LxcMoveVolumeRequest {
54        LxcMoveVolumeRequest {
55            
56            bwlimit: None,
57            
58            delete: None,
59            
60            digest: None,
61            
62            storage: None,
63            
64            target_digest: None,
65            
66            target_vmid: None,
67            
68            target_volume: None,
69            
70            volume,
71            
72        }
73    }
74}
75
76