#[non_exhaustive]pub struct JobRow {
pub id: String,
pub title: String,
pub state: RowState,
pub progress: Option<f64>,
pub detail: Option<String>,
pub badge: Option<JobBadge>,
pub group: Option<String>,
pub actions: Vec<RowAction>,
}Expand description
One row of a source.
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.id: StringUnique within its source.
title: String§state: RowState§progress: Option<f64>How far it is, 0 to 1; none when it cannot tell.
detail: Option<String>A line under its bar, also its tooltip.
badge: Option<JobBadge>A registry symbol before its title, its tip its accessible name.
group: Option<String>The group it sits under, within its source.
actions: Vec<RowAction>Implementations§
Source§impl JobRow
impl JobRow
pub fn new( id: impl Into<String>, title: impl Into<String>, state: RowState, ) -> Self
pub fn progress(self, fraction: f64) -> Self
pub fn detail(self, detail: impl Into<String>) -> Self
pub fn badge(self, badge: JobBadge) -> Self
pub fn group(self, group: impl Into<String>) -> Self
pub fn action(self, action: RowAction) -> Self
Trait Implementations§
Source§impl<'de> Deserialize<'de> for JobRow
impl<'de> Deserialize<'de> for JobRow
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for JobRow
Auto Trait Implementations§
impl Freeze for JobRow
impl RefUnwindSafe for JobRow
impl Send for JobRow
impl Sync for JobRow
impl Unpin for JobRow
impl UnsafeUnpin for JobRow
impl UnwindSafe for JobRow
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