pub enum AutolinkKind {
Angle,
GfmLiteral {
original: String,
},
}Expand description
Whether an Autolink is angle-bracketed or a GFM bare literal.
Variants§
Angle
An angle-bracket autolink <dest>. The destination is the raw text
between the brackets; > is forbidden in the destination and the
serializer re-emits <dest>.
GfmLiteral
A GFM literal autolink (bare www./http(s):///mailto:/xmpp: URL
or email). original is the raw source text that produced the link
(the visible label); destination is the synthesized href (e.g. a
http:///mailto: prefix may have been prepended). The serializer
re-emits original, which re-parses to the same literal.
Trait Implementations§
Source§impl Clone for AutolinkKind
impl Clone for AutolinkKind
Source§fn clone(&self) -> AutolinkKind
fn clone(&self) -> AutolinkKind
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 AutolinkKind
impl Debug for AutolinkKind
impl Eq for AutolinkKind
Source§impl PartialEq for AutolinkKind
impl PartialEq for AutolinkKind
Source§fn eq(&self, other: &AutolinkKind) -> bool
fn eq(&self, other: &AutolinkKind) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for AutolinkKind
Auto Trait Implementations§
impl Freeze for AutolinkKind
impl RefUnwindSafe for AutolinkKind
impl Send for AutolinkKind
impl Sync for AutolinkKind
impl Unpin for AutolinkKind
impl UnsafeUnpin for AutolinkKind
impl UnwindSafe for AutolinkKind
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