pub struct Link {
pub href: String,
pub media_type: Option<String>,
pub rel: Option<String>,
pub resource_fragment: Option<String>,
pub text: Option<String>,
}Expand description
A reference to a local or remote resource, that has a specific relation to the containing object.
Fields§
§href: StringA resolvable URL reference to a resource.
media_type: Option<String>A label that indicates the nature of a resource, as a data serialization or format.
rel: Option<String>Describes the type of relationship provided by the link’s hypertext reference. This can be an indicator of the link’s purpose.
resource_fragment: Option<String>In case where the href points to a back-matter/resource, this value will indicate the URI fragment to append to any rlink associated with the resource. This value MUST be URI encoded.
text: Option<String>A textual label to associate with the link, which may be used for presentation in a tool.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Link
impl<'de> Deserialize<'de> for Link
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
Auto Trait Implementations§
impl Freeze for Link
impl RefUnwindSafe for Link
impl Send for Link
impl Sync for Link
impl Unpin for Link
impl UnwindSafe for Link
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