pub enum CommandResult {
Report(Report),
Failure(Failure),
None,
}
Expand description
what we get from the execution of a command
Variants§
Report(Report)
a trustable report with errors and warnings computed
Failure(Failure)
we don’t have a proper report
None
not yet computed
Implementations§
Source§impl CommandResult
impl CommandResult
pub fn build( output: CommandOutput, exit_status: Option<ExitStatus>, report: Report, ) -> Result<Self>
pub fn output(&self) -> Option<&CommandOutput>
pub fn report(&self) -> Option<&Report>
pub fn suggest_backtrace(&self) -> bool
Sourcepub fn is_success(&self) -> bool
pub fn is_success(&self) -> bool
return true when the report has been computed and there’s been no error, warning, or test failures
This is different from the is_success that a mission can compute from a report using its own settings (eg allow_warnings)
pub fn reverse(&mut self)
pub fn lines_len(&self) -> usize
Trait Implementations§
Source§impl Clone for CommandResult
impl Clone for CommandResult
Source§fn clone(&self) -> CommandResult
fn clone(&self) -> CommandResult
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 CommandResult
impl Debug for CommandResult
Source§impl<'de> Deserialize<'de> for CommandResult
impl<'de> Deserialize<'de> for CommandResult
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
Auto Trait Implementations§
impl Freeze for CommandResult
impl RefUnwindSafe for CommandResult
impl Send for CommandResult
impl Sync for CommandResult
impl Unpin for CommandResult
impl UnwindSafe for CommandResult
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> IQ for Twhere
T: Serialize,
impl<T> IQ for Twhere
T: Serialize,
Source§fn extract_primitive<P>(&self, path: P) -> Option<String>where
P: IqPath,
fn extract_primitive<P>(&self, path: P) -> Option<String>where
P: IqPath,
Extract a “primitive” value (including strings, simple enum variants, etc)
as a string using the Display implementation of the deep value.
Source§fn extract_json_pretty<P>(&self, path: P) -> Option<String>where
P: IqPath,
fn extract_json_pretty<P>(&self, path: P) -> Option<String>where
P: IqPath,
Extract a value as JSON, pretty
Source§fn extract_value<P, V>(&self, path: P) -> Result<Option<V>, IqError>where
P: IqPath,
V: DeserializeOwned,
fn extract_value<P, V>(&self, path: P) -> Result<Option<V>, IqError>where
P: IqPath,
V: DeserializeOwned,
Extract a value in a type which must implement
Deserialize
, from a value, at
the given path. Read more