proxmox_api/generated/nodes/node/
version.rs

1pub struct VersionClient<T> {
2    client: T,
3    path: String,
4}
5impl<T> VersionClient<T>
6where
7    T: crate::client::Client,
8{
9    pub fn new(client: T, parent_path: &str) -> Self {
10        Self {
11            client,
12            path: format!("{}{}", parent_path, "/version"),
13        }
14    }
15}
16impl<T> VersionClient<T>
17where
18    T: crate::client::Client,
19{
20    #[doc = "API version details"]
21    pub fn get(&self) -> Result<GetOutput, T::Error> {
22        let path = self.path.to_string();
23        self.client.get(&path, &())
24    }
25}
26impl GetOutput {
27    pub fn new(release: String, repoid: String, version: String) -> Self {
28        Self {
29            release,
30            repoid,
31            version,
32            additional_properties: Default::default(),
33        }
34    }
35}
36#[derive(Clone, Debug, :: serde :: Serialize, :: serde :: Deserialize)]
37pub struct GetOutput {
38    #[doc = "The current installed Proxmox VE Release"]
39    pub release: String,
40    #[doc = "The short git commit hash ID from which this version was build"]
41    pub repoid: String,
42    #[doc = "The current installed pve-manager package version"]
43    pub version: String,
44    #[serde(
45        flatten,
46        default,
47        skip_serializing_if = "::std::collections::HashMap::is_empty"
48    )]
49    pub additional_properties: ::std::collections::HashMap<String, ::serde_json::Value>,
50}