pub struct OneShotStatusTracker { /* private fields */ }
Expand description
A OneShotStatusTracker
will trigger an error upon the first call to its
add_error
function, which is designed to abort any unnecessary
computation if the overall result is unnecessary.
Trait Implementations§
Source§impl Debug for OneShotStatusTracker
impl Debug for OneShotStatusTracker
Source§impl Default for OneShotStatusTracker
impl Default for OneShotStatusTracker
Source§fn default() -> OneShotStatusTracker
fn default() -> OneShotStatusTracker
Returns the “default value” for a type. Read more
Source§impl StatusTracker for OneShotStatusTracker
impl StatusTracker for OneShotStatusTracker
Source§fn logged_items(&self) -> &[LogItem]
fn logged_items(&self) -> &[LogItem]
Return the current list of validation log items.
Source§fn add_non_error(&mut self, log_item: LogItem)
fn add_non_error(&mut self, log_item: LogItem)
Source§fn append(&mut self, other: &impl StatusTracker)
fn append(&mut self, other: &impl StatusTracker)
Appends the contents of another
StatusTracker
to this list of
validation log items.Source§fn filter_errors(&mut self) -> impl Iterator<Item = &LogItem>
fn filter_errors(&mut self) -> impl Iterator<Item = &LogItem>
Source§fn has_status(&self, val: &str) -> bool
fn has_status(&self, val: &str) -> bool
Return
true
if the validation log contains a specific C2PA status
code.Source§fn has_error<E: Debug>(&self, err: E) -> bool
fn has_error<E: Debug>(&self, err: E) -> bool
Return
true
if the validation log contains a specific error.Source§fn push_ingredient_uri<S: Into<String>>(&mut self, _uri: S)
fn push_ingredient_uri<S: Into<String>>(&mut self, _uri: S)
Keeps track of the current ingredient URI, if any. Read more
Source§fn pop_ingredient_uri(&mut self) -> Option<String>
fn pop_ingredient_uri(&mut self) -> Option<String>
Removes the current ingredient URI, if any.
Auto Trait Implementations§
impl Freeze for OneShotStatusTracker
impl RefUnwindSafe for OneShotStatusTracker
impl Send for OneShotStatusTracker
impl Sync for OneShotStatusTracker
impl Unpin for OneShotStatusTracker
impl UnwindSafe for OneShotStatusTracker
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