proxmox_api/generated/nodes/node/hardware/pci/
pciid.rs1pub mod mdev;
2pub struct PciidClient<T> {
3 client: T,
4 path: String,
5}
6impl<T> PciidClient<T>
7where
8 T: crate::client::Client,
9{
10 pub fn new(client: T, parent_path: &str, pciid: &str) -> Self {
11 Self {
12 client,
13 path: format!("{}/{}", parent_path, pciid),
14 }
15 }
16}
17impl<T> PciidClient<T>
18where
19 T: crate::client::Client,
20{
21 #[doc = "Index of available pci methods"]
22 pub fn get(&self) -> Result<Vec<GetOutputItems>, T::Error> {
23 let path = self.path.to_string();
24 self.client.get(&path, &())
25 }
26}
27impl GetOutputItems {
28 pub fn new(method: String) -> Self {
29 Self {
30 method,
31 additional_properties: Default::default(),
32 }
33 }
34}
35#[derive(Clone, Debug, :: serde :: Serialize, :: serde :: Deserialize)]
36pub struct GetOutputItems {
37 pub method: String,
38 #[serde(
39 flatten,
40 default,
41 skip_serializing_if = "::std::collections::HashMap::is_empty"
42 )]
43 pub additional_properties: ::std::collections::HashMap<String, ::serde_json::Value>,
44}
45impl<T> PciidClient<T>
46where
47 T: crate::client::Client,
48{
49 pub fn mdev(&self) -> mdev::MdevClient<T> {
50 mdev::MdevClient::<T>::new(self.client.clone(), &self.path)
51 }
52}