#[non_exhaustive]pub enum RefKind {
Url,
Citation,
Footnote,
Session,
File,
Placeholder,
Unsure,
General,
}Expand description
Sub-kind of an inline reference.
Forward compatibility is implemented in the Deserialize impl: any
string that doesn’t match a known variant deserialises as
RefKind::General, matching the wire spec’s “handlers must treat
unknown ref_kind values as general” rule. The #[non_exhaustive]
attribute makes adding new variants a non-breaking Rust change.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Trait Implementations§
impl Copy for RefKind
Source§impl<'de> Deserialize<'de> for RefKind
impl<'de> Deserialize<'de> for RefKind
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 RefKind
impl StructuralPartialEq for RefKind
Auto Trait Implementations§
impl Freeze for RefKind
impl RefUnwindSafe for RefKind
impl Send for RefKind
impl Sync for RefKind
impl Unpin for RefKind
impl UnsafeUnpin for RefKind
impl UnwindSafe for RefKind
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