pub struct HealthAlert {
pub kind: HealthAlertKind,
pub severity: AlertSeverity,
pub message: String,
pub details: Option<String>,
}Expand description
Health alert
Fields§
§kind: HealthAlertKindKind
severity: AlertSeveritySeverity
message: StringAlert message (for English fallback)
details: Option<String>Detailed description
Implementations§
Source§impl HealthAlert
impl HealthAlert
Sourcepub fn new(
kind: HealthAlertKind,
severity: AlertSeverity,
message: impl Into<String>,
) -> Self
pub fn new( kind: HealthAlertKind, severity: AlertSeverity, message: impl Into<String>, ) -> Self
Create a new alert
Sourcepub fn with_details(
kind: HealthAlertKind,
severity: AlertSeverity,
message: impl Into<String>,
details: impl Into<String>,
) -> Self
pub fn with_details( kind: HealthAlertKind, severity: AlertSeverity, message: impl Into<String>, details: impl Into<String>, ) -> Self
Create an alert with details
Trait Implementations§
Source§impl Clone for HealthAlert
impl Clone for HealthAlert
Source§fn clone(&self) -> HealthAlert
fn clone(&self) -> HealthAlert
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 HealthAlert
impl RefUnwindSafe for HealthAlert
impl Send for HealthAlert
impl Sync for HealthAlert
impl Unpin for HealthAlert
impl UnsafeUnpin for HealthAlert
impl UnwindSafe for HealthAlert
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more