pub struct ProviderPartInfo {
pub id: Option<String>,
pub provider_name: Option<String>,
pub details: Metadata,
}Expand description
Provider-private replay metadata attached to response parts.
Fields§
§id: Option<String>Provider output item identifier, when the provider exposes one separately from call IDs.
provider_name: Option<String>Provider that produced the part.
details: MetadataProvider-private fields needed for same-provider replay and diagnostics.
Implementations§
Source§impl ProviderPartInfo
impl ProviderPartInfo
Sourcepub fn new(provider_name: impl Into<String>) -> Self
pub fn new(provider_name: impl Into<String>) -> Self
Build provider metadata for one provider output item.
Sourcepub fn with_details(self, details: Metadata) -> Self
pub fn with_details(self, details: Metadata) -> Self
Attach provider details.
Sourcepub fn is_provider(&self, provider_name: &str) -> bool
pub fn is_provider(&self, provider_name: &str) -> bool
Returns true when this metadata belongs to provider_name.
Trait Implementations§
Source§impl Clone for ProviderPartInfo
impl Clone for ProviderPartInfo
Source§fn clone(&self) -> ProviderPartInfo
fn clone(&self) -> ProviderPartInfo
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 ProviderPartInfo
impl Debug for ProviderPartInfo
Source§impl Default for ProviderPartInfo
impl Default for ProviderPartInfo
Source§fn default() -> ProviderPartInfo
fn default() -> ProviderPartInfo
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ProviderPartInfo
impl<'de> Deserialize<'de> for ProviderPartInfo
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
impl Eq for ProviderPartInfo
Source§impl PartialEq for ProviderPartInfo
impl PartialEq for ProviderPartInfo
Source§impl Serialize for ProviderPartInfo
impl Serialize for ProviderPartInfo
impl StructuralPartialEq for ProviderPartInfo
Auto Trait Implementations§
impl Freeze for ProviderPartInfo
impl RefUnwindSafe for ProviderPartInfo
impl Send for ProviderPartInfo
impl Sync for ProviderPartInfo
impl Unpin for ProviderPartInfo
impl UnsafeUnpin for ProviderPartInfo
impl UnwindSafe for ProviderPartInfo
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