podman_client/models/podman/common/
linux_throttle_device.rs

1use core::fmt;
2
3use serde::{Deserialize, Serialize};
4
5#[derive(Deserialize, Serialize, Default)]
6pub struct LinuxThrottleDevice {
7    pub major: Option<i64>,
8    pub minor: Option<i64>,
9    pub rate: Option<u64>,
10}
11
12impl fmt::Debug for LinuxThrottleDevice {
13    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14        let json = serde_json::to_string_pretty(self).map_err(|_| fmt::Error)?;
15        f.write_str(&json)
16    }
17}