pub enum YoctoFailureKind {
DoBuild,
DoCompile,
DoCompilePtestBase,
DoConfigure,
DoConfigurePtestBase,
DoDeploy,
DoFetch,
Misc,
}
Variants§
DoBuild
The 6 standard tasks in Yocto https://docs.yoctoproject.org/ref-manual/tasks.html
DoCompile
DoCompilePtestBase
DoConfigure
DoConfigurePtestBase
DoDeploy
DoFetch
Other tasks
Misc
If it’s a type of failure we’re not familiar with or parsing fails, default to this
Implementations§
source§impl YoctoFailureKind
impl YoctoFailureKind
sourcepub fn parse_from_logfilename(fname: &str) -> Result<Self, Box<dyn Error>>
pub fn parse_from_logfilename(fname: &str) -> Result<Self, Box<dyn Error>>
Takes in a yocto logfile filename such as log.do_fetch.21616
and attempts to determine the type
of yocto task the the logfile is associated with.
§Example
let kind = YoctoFailureKind::parse_from_logfilename("log.do_fetch.21616").unwrap();
assert_eq!(kind, YoctoFailureKind::DoFetch);
// Infallible if you're sure the filename is a yocto log but it might not be a known task
let kind = YoctoFailureKind::parse_from_logfilename("log.some_custom_task.21616").unwrap_or_default();
assert_eq!(kind, YoctoFailureKind::Misc);
Trait Implementations§
source§impl Clone for YoctoFailureKind
impl Clone for YoctoFailureKind
source§fn clone(&self) -> YoctoFailureKind
fn clone(&self) -> YoctoFailureKind
Returns a copy 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 YoctoFailureKind
impl Debug for YoctoFailureKind
source§impl Default for YoctoFailureKind
impl Default for YoctoFailureKind
source§fn default() -> YoctoFailureKind
fn default() -> YoctoFailureKind
Returns the “default value” for a type. Read more
source§impl Display for YoctoFailureKind
impl Display for YoctoFailureKind
source§impl FromStr for YoctoFailureKind
impl FromStr for YoctoFailureKind
source§impl IntoEnumIterator for YoctoFailureKind
impl IntoEnumIterator for YoctoFailureKind
type Iterator = YoctoFailureKindIter
fn iter() -> YoctoFailureKindIter ⓘ
source§impl Ord for YoctoFailureKind
impl Ord for YoctoFailureKind
source§fn cmp(&self, other: &YoctoFailureKind) -> Ordering
fn cmp(&self, other: &YoctoFailureKind) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for YoctoFailureKind
impl PartialEq for YoctoFailureKind
source§fn eq(&self, other: &YoctoFailureKind) -> bool
fn eq(&self, other: &YoctoFailureKind) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for YoctoFailureKind
impl PartialOrd for YoctoFailureKind
source§fn partial_cmp(&self, other: &YoctoFailureKind) -> Option<Ordering>
fn partial_cmp(&self, other: &YoctoFailureKind) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl TryFrom<&str> for YoctoFailureKind
impl TryFrom<&str> for YoctoFailureKind
impl Copy for YoctoFailureKind
impl Eq for YoctoFailureKind
impl StructuralPartialEq for YoctoFailureKind
Auto Trait Implementations§
impl RefUnwindSafe for YoctoFailureKind
impl Send for YoctoFailureKind
impl Sync for YoctoFailureKind
impl Unpin for YoctoFailureKind
impl UnwindSafe for YoctoFailureKind
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