pub struct DiskStat {
pub device_name: Option<String>,
pub read_sectors: Option<u64>,
pub read_time_ms: Option<u64>,
pub write_sectors: Option<u64>,
pub write_time_ms: Option<u64>,
pub discard_sectors: Option<u64>,
pub discard_time_ms: Option<u64>,
pub flush_count: Option<u64>,
pub flush_time_ms: Option<u64>,
}Expand description
Counters from /proc/diskstats.
Fields§
§device_name: Option<String>§read_sectors: Option<u64>§read_time_ms: Option<u64>§write_sectors: Option<u64>§write_time_ms: Option<u64>§discard_sectors: Option<u64>§discard_time_ms: Option<u64>§flush_count: Option<u64>§flush_time_ms: Option<u64>Implementations§
Source§impl DiskStat
impl DiskStat
Sourcepub fn device_name(&self) -> &str
pub fn device_name(&self) -> &str
Returns the value of device_name, or the default value if device_name is unset.
Sourcepub fn read_sectors(&self) -> u64
pub fn read_sectors(&self) -> u64
Returns the value of read_sectors, or the default value if read_sectors is unset.
Sourcepub fn read_time_ms(&self) -> u64
pub fn read_time_ms(&self) -> u64
Returns the value of read_time_ms, or the default value if read_time_ms is unset.
Sourcepub fn write_sectors(&self) -> u64
pub fn write_sectors(&self) -> u64
Returns the value of write_sectors, or the default value if write_sectors is unset.
Sourcepub fn write_time_ms(&self) -> u64
pub fn write_time_ms(&self) -> u64
Returns the value of write_time_ms, or the default value if write_time_ms is unset.
Sourcepub fn discard_sectors(&self) -> u64
pub fn discard_sectors(&self) -> u64
Returns the value of discard_sectors, or the default value if discard_sectors is unset.
Sourcepub fn discard_time_ms(&self) -> u64
pub fn discard_time_ms(&self) -> u64
Returns the value of discard_time_ms, or the default value if discard_time_ms is unset.
Sourcepub fn flush_count(&self) -> u64
pub fn flush_count(&self) -> u64
Returns the value of flush_count, or the default value if flush_count is unset.
Sourcepub fn flush_time_ms(&self) -> u64
pub fn flush_time_ms(&self) -> u64
Returns the value of flush_time_ms, or the default value if flush_time_ms is unset.
Trait Implementations§
Source§impl Message for DiskStat
impl Message for DiskStat
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.impl StructuralPartialEq for DiskStat
Auto Trait Implementations§
impl Freeze for DiskStat
impl RefUnwindSafe for DiskStat
impl Send for DiskStat
impl Sync for DiskStat
impl Unpin for DiskStat
impl UnwindSafe for DiskStat
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].