pub struct ToolWarning {
pub code: WarningCode,
pub message: String,
pub field: Option<String>,
pub value: Option<String>,
}Expand description
A warning about a non-fatal issue in a tool operation.
Fields§
§code: WarningCode§message: String§field: Option<String>§value: Option<String>Implementations§
Source§impl ToolWarning
impl ToolWarning
pub fn new(code: WarningCode, message: impl Into<String>) -> Self
pub fn with_field(self, field: impl Into<String>) -> Self
pub fn with_value(self, value: impl Into<String>) -> Self
pub fn task_not_found(task_id: &str) -> Self
pub fn dependency_not_found(task_id: &str, field: &str) -> Self
pub fn unknown_tag(tag: &str) -> Self
pub fn unknown_phase(phase: &str) -> Self
pub fn duplicate(what: &str) -> Self
pub fn deprecated(feature: &str, alternative: &str) -> Self
Trait Implementations§
Source§impl Clone for ToolWarning
impl Clone for ToolWarning
Source§fn clone(&self) -> ToolWarning
fn clone(&self) -> ToolWarning
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 moreSource§impl Debug for ToolWarning
impl Debug for ToolWarning
Source§impl Display for ToolWarning
impl Display for ToolWarning
Auto Trait Implementations§
impl Freeze for ToolWarning
impl RefUnwindSafe for ToolWarning
impl Send for ToolWarning
impl Sync for ToolWarning
impl Unpin for ToolWarning
impl UnsafeUnpin for ToolWarning
impl UnwindSafe for ToolWarning
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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