pub struct ResponseSource {
pub priority: ResponsePriority,
pub source_type: String,
pub metadata: HashMap<String, String>,
}
Expand description
Response source information
Fields§
§priority: ResponsePriority
Priority level of this response
source_type: String
Source type
metadata: HashMap<String, String>
Additional metadata
Implementations§
Source§impl ResponseSource
impl ResponseSource
Sourcepub fn new(priority: ResponsePriority, source_type: String) -> Self
pub fn new(priority: ResponsePriority, source_type: String) -> Self
Create a new response source
Sourcepub fn with_metadata(self, key: String, value: String) -> Self
pub fn with_metadata(self, key: String, value: String) -> Self
Add metadata to the response source
Trait Implementations§
Source§impl Clone for ResponseSource
impl Clone for ResponseSource
Source§fn clone(&self) -> ResponseSource
fn clone(&self) -> ResponseSource
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 moreAuto Trait Implementations§
impl Freeze for ResponseSource
impl RefUnwindSafe for ResponseSource
impl Send for ResponseSource
impl Sync for ResponseSource
impl Unpin for ResponseSource
impl UnwindSafe for ResponseSource
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