[][src]Struct bevy_diagnostic::Diagnostic

pub struct Diagnostic {
    pub id: DiagnosticId,
    pub name: String,
    // some fields omitted
}

A timeline of DiagnosticMeasurements of a specific type. Diagnostic examples: frames per second, CPU usage, network latency

Fields

id: DiagnosticIdname: String

Implementations

impl Diagnostic[src]

pub fn add_measurement(&mut self, value: f64)[src]

pub fn new(
    id: DiagnosticId,
    name: &str,
    max_history_length: usize
) -> Diagnostic
[src]

pub fn value(&self) -> Option<f64>[src]

pub fn sum(&self) -> f64[src]

pub fn average(&self) -> Option<f64>[src]

pub fn history_len(&self) -> usize[src]

pub fn duration(&self) -> Option<Duration>[src]

pub fn get_max_history_length(&self) -> usize[src]

Trait Implementations

impl Debug for Diagnostic[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Component for T where
    T: 'static + Send + Sync

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Resource for T where
    T: 'static + Send + Sync
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,