pub trait Metadata:
DeserializeOwned
+ Serialize
+ Clone
+ Send {
type Error: Clone + MetadataError;
// Required methods
fn timestamp(&self) -> Timestamp;
fn errors(&self) -> Option<&[Self::Error]>;
fn set_errors(&mut self, errors: Vec<Self::Error>);
// Provided method
fn has_errors(&self) -> bool { ... }
}
Required Associated Types§
Sourcetype Error: Clone + MetadataError
type Error: Clone + MetadataError
The type of error returned in this metadata.
Required Methods§
Sourcefn errors(&self) -> Option<&[Self::Error]>
fn errors(&self) -> Option<&[Self::Error]>
Returns the errors recorded with this value, if any.
Sourcefn set_errors(&mut self, errors: Vec<Self::Error>)
fn set_errors(&mut self, errors: Vec<Self::Error>)
Overrides the errors associated with this value.
Provided Methods§
Sourcefn has_errors(&self) -> bool
fn has_errors(&self) -> bool
Returns whether any errors are recorded on this value.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.