proxmox_api/generated/nodes/node/scan/
nfs.rs1pub struct NfsClient<T> {
2 client: T,
3 path: String,
4}
5impl<T> NfsClient<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, "/nfs"),
13 }
14 }
15}
16impl<T> NfsClient<T>
17where
18 T: crate::client::Client,
19{
20 #[doc = "Scan remote NFS server."]
21 pub fn get(&self, params: GetParams) -> Result<Vec<GetOutputItems>, T::Error> {
22 let path = self.path.to_string();
23 self.client.get(&path, ¶ms)
24 }
25}
26impl GetOutputItems {
27 pub fn new(options: String, path: String) -> Self {
28 Self {
29 options,
30 path,
31 additional_properties: Default::default(),
32 }
33 }
34}
35#[derive(Clone, Debug, :: serde :: Serialize, :: serde :: Deserialize)]
36pub struct GetOutputItems {
37 #[doc = "NFS export options."]
38 pub options: String,
39 #[doc = "The exported path."]
40 pub path: String,
41 #[serde(
42 flatten,
43 default,
44 skip_serializing_if = "::std::collections::HashMap::is_empty"
45 )]
46 pub additional_properties: ::std::collections::HashMap<String, ::serde_json::Value>,
47}
48impl GetParams {
49 pub fn new(server: String) -> Self {
50 Self {
51 server,
52 additional_properties: Default::default(),
53 }
54 }
55}
56#[derive(Clone, Debug, :: serde :: Serialize, :: serde :: Deserialize)]
57pub struct GetParams {
58 #[doc = "The server address (name or IP)."]
59 pub server: String,
60 #[serde(
61 flatten,
62 default,
63 skip_serializing_if = "::std::collections::HashMap::is_empty"
64 )]
65 pub additional_properties: ::std::collections::HashMap<String, ::serde_json::Value>,
66}