#[non_exhaustive]pub struct PacketIntervals {
pub avg_ms: Option<i64>,
pub duration: Option<Duration>,
pub max_ms: Option<i64>,
pub min_ms: Option<i64>,
pub num_intervals: Option<i64>,
pub type: Option<Type>,
/* private fields */
}Available on crate feature
routers only.Expand description
Next free: 7
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.avg_ms: Option<i64>Average observed inter-packet interval in milliseconds.
duration: Option<Duration>From how long ago in the past these intervals were observed.
max_ms: Option<i64>Maximum observed inter-packet interval in milliseconds.
min_ms: Option<i64>Minimum observed inter-packet interval in milliseconds.
num_intervals: Option<i64>Number of inter-packet intervals from which these statistics were derived.
type: Option<Type>The type of packets for which inter-packet intervals were computed.
Implementations§
Source§impl PacketIntervals
impl PacketIntervals
pub fn new() -> Self
Sourcepub fn set_avg_ms<T>(self, v: T) -> Self
pub fn set_avg_ms<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_avg_ms<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_avg_ms<T>(self, v: Option<T>) -> Self
Sourcepub fn set_duration<T>(self, v: T) -> Self
pub fn set_duration<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_duration<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_duration<T>(self, v: Option<T>) -> Self
Sets or clears the value of duration.
§Example
ⓘ
use google_cloud_compute_v1::model::packet_intervals::Duration;
let x0 = PacketIntervals::new().set_or_clear_duration(Some(Duration::Hour));
let x1 = PacketIntervals::new().set_or_clear_duration(Some(Duration::Max));
let x2 = PacketIntervals::new().set_or_clear_duration(Some(Duration::Minute));
let x_none = PacketIntervals::new().set_or_clear_duration(None::<Duration>);Sourcepub fn set_max_ms<T>(self, v: T) -> Self
pub fn set_max_ms<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_max_ms<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_max_ms<T>(self, v: Option<T>) -> Self
Sourcepub fn set_min_ms<T>(self, v: T) -> Self
pub fn set_min_ms<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_min_ms<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_min_ms<T>(self, v: Option<T>) -> Self
Sourcepub fn set_num_intervals<T>(self, v: T) -> Self
pub fn set_num_intervals<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_num_intervals<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_num_intervals<T>(self, v: Option<T>) -> Self
Sets or clears the value of num_intervals.
§Example
ⓘ
let x = PacketIntervals::new().set_or_clear_num_intervals(Some(42));
let x = PacketIntervals::new().set_or_clear_num_intervals(None::<i32>);Sourcepub fn set_or_clear_type<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_type<T>(self, v: Option<T>) -> Self
Sets or clears the value of r#type.
§Example
ⓘ
use google_cloud_compute_v1::model::packet_intervals::Type;
let x0 = PacketIntervals::new().set_or_clear_type(Some(Type::Receive));
let x1 = PacketIntervals::new().set_or_clear_type(Some(Type::Transmit));
let x2 = PacketIntervals::new().set_or_clear_type(Some(Type::Unspecified));
let x_none = PacketIntervals::new().set_or_clear_type(None::<Type>);Trait Implementations§
Source§impl Clone for PacketIntervals
impl Clone for PacketIntervals
Source§fn clone(&self) -> PacketIntervals
fn clone(&self) -> PacketIntervals
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PacketIntervals
impl Debug for PacketIntervals
Source§impl Default for PacketIntervals
impl Default for PacketIntervals
Source§fn default() -> PacketIntervals
fn default() -> PacketIntervals
Returns the “default value” for a type. Read more
Source§impl Message for PacketIntervals
impl Message for PacketIntervals
Source§impl PartialEq for PacketIntervals
impl PartialEq for PacketIntervals
impl StructuralPartialEq for PacketIntervals
Auto Trait Implementations§
impl Freeze for PacketIntervals
impl RefUnwindSafe for PacketIntervals
impl Send for PacketIntervals
impl Sync for PacketIntervals
impl Unpin for PacketIntervals
impl UnwindSafe for PacketIntervals
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
Mutably borrows from an owned value. Read more