pub struct Relation {
pub rels: Vec<String>,
pub hreflang: Option<String>,
pub media: Option<String>,
pub title: Option<String>,
pub type: Option<String>,
pub text: Option<String>,
}
Fields§
§rels: Vec<String>
§hreflang: Option<String>
§media: Option<String>
§title: Option<String>
§type: Option<String>
§text: Option<String>
Implementations§
Source§impl Relation
impl Relation
Sourcepub fn merge_with(&mut self, other: Self)
pub fn merge_with(&mut self, other: Self)
Fuses the values of the other relation with this one.
Sourcepub fn to_header_value(&self, base_url: &Url) -> String
pub fn to_header_value(&self, base_url: &Url) -> String
Generates a value to be used in a header.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Relation
impl<'de> Deserialize<'de> for Relation
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
Source§impl Ord for Relation
impl Ord for Relation
Source§impl PartialOrd for Relation
impl PartialOrd for Relation
impl Eq for Relation
impl StructuralPartialEq for Relation
Auto Trait Implementations§
impl Freeze for Relation
impl RefUnwindSafe for Relation
impl Send for Relation
impl Sync for Relation
impl Unpin for Relation
impl UnwindSafe for Relation
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.