Trait BrokenLinkCallback

Source
pub trait BrokenLinkCallback:
    RefUnwindSafe
    + Send
    + Sync {
    // Required method
    fn resolve(
        &self,
        broken_link_reference: BrokenLinkReference<'_>,
    ) -> Option<ResolvedReference>;
}
Expand description

The type of the callback used when a reference link is encountered with no matching reference.

The details of the broken reference are passed in the BrokenLinkReference argument. If a ResolvedReference is returned, it is used as the link; otherwise, no link is made and the reference text is preserved in its entirety.

Required Methods§

Source

fn resolve( &self, broken_link_reference: BrokenLinkReference<'_>, ) -> Option<ResolvedReference>

Potentially resolve a single broken link reference.

Trait Implementations§

Source§

impl<'c> Debug for dyn BrokenLinkCallback + 'c

Source§

fn fmt(&self, formatter: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more

Implementors§