proxmox_api/generated/cluster/
backup_info.rs1pub mod not_backed_up;
2#[derive(Debug, Clone)]
3pub struct BackupInfoClient<T> {
4 client: T,
5 path: String,
6}
7impl<T> BackupInfoClient<T>
8where
9 T: crate::client::Client,
10{
11 pub fn new(client: T, parent_path: &str) -> Self {
12 Self {
13 client,
14 path: format!("{}{}", parent_path, "/backup-info"),
15 }
16 }
17}
18impl<T> BackupInfoClient<T>
19where
20 T: crate::client::Client,
21{
22 #[doc = "Index for backup info related endpoints"]
23 #[doc = ""]
24 pub async fn get(&self) -> Result<Vec<GetOutputItems>, T::Error> {
25 let path = self.path.to_string();
26 let optional_vec: Option<Vec<GetOutputItems>> = self.client.get(&path, &()).await?;
27 Ok(optional_vec.unwrap_or_default())
28 }
29}
30impl GetOutputItems {
31 pub fn new(subdir: String) -> Self {
32 Self {
33 subdir,
34 additional_properties: ::std::default::Default::default(),
35 }
36 }
37}
38#[derive(Clone, Debug, :: serde :: Serialize, :: serde :: Deserialize)]
39pub struct GetOutputItems {
40 #[doc = "API sub-directory endpoint"]
41 #[doc = ""]
42 pub subdir: String,
43 #[serde(
44 flatten,
45 default,
46 skip_serializing_if = "::std::collections::HashMap::is_empty"
47 )]
48 pub additional_properties: ::std::collections::HashMap<String, ::serde_json::Value>,
49}
50impl<T> BackupInfoClient<T>
51where
52 T: crate::client::Client,
53{
54 pub fn not_backed_up(&self) -> not_backed_up::NotBackedUpClient<T> {
55 not_backed_up::NotBackedUpClient::<T>::new(self.client.clone(), &self.path)
56 }
57}