pub struct DashboardState {
pub identity: DashboardIdentity,
pub mode: &'static str,
pub snapshot_fn: SnapshotFn,
pub event_tx: Sender<DashboardSseEvent>,
pub started_at: Instant,
}Expand description
Shared state for the dashboard routes.
Construct this in the binary crate or koi-embedded and inject it
via axum::Extension.
Fields§
§identity: DashboardIdentity§mode: &'static str§snapshot_fn: SnapshotFn§event_tx: Sender<DashboardSseEvent>§started_at: InstantTrait Implementations§
Source§impl Clone for DashboardState
impl Clone for DashboardState
Source§fn clone(&self) -> DashboardState
fn clone(&self) -> DashboardState
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 moreAuto Trait Implementations§
impl Freeze for DashboardState
impl !RefUnwindSafe for DashboardState
impl Send for DashboardState
impl Sync for DashboardState
impl Unpin for DashboardState
impl UnsafeUnpin for DashboardState
impl !UnwindSafe for DashboardState
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