pub enum Limit {
Int(u64),
Float(f64),
}
Available on crate feature
default
only.Expand description
A Limit
which can be either an integer or a float
Depending on the metric the type of the hard limit is a float or an integer. For example
EventKind::Ir
is an integer and EventKind::L1HitRate
is a percentage and therefore a
float.
The type of the metric can be seen in the terminal output of Iai-Callgrind: Floats always
contain a .
and integers do not.
Variants§
Int(u64)
An integer Limit
. For example EventKind::Ir
Float(f64)
A float Limit
. For example EventKind::L1HitRate
or EventKind::I1MissRate
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Limit
impl<'de> Deserialize<'de> for Limit
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Limit, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Limit, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for Limit
impl Serialize for Limit
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Copy for Limit
impl StructuralPartialEq for Limit
Auto Trait Implementations§
impl Freeze for Limit
impl RefUnwindSafe for Limit
impl Send for Limit
impl Sync for Limit
impl Unpin for Limit
impl UnwindSafe for Limit
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