pub struct CalloutRef {
pub kind: CalloutRefKind,
pub number: usize,
pub location: Location,
}Expand description
A CalloutRef represents a callout reference marker within verbatim content.
Callout references appear at the end of lines in source/listing blocks and link to explanatory text in a subsequent callout list.
§Examples
[source,ruby]
----
def main <1>
puts 'hello' <.>
end
----
<1> Defines the main function
<.> Prints a greetingThe <1> marker creates an Explicit callout ref, while <.> creates an
Auto callout ref that gets resolved to the next available number.
Fields§
§kind: CalloutRefKindThe kind of callout (explicit number vs auto-numbered).
number: usizeThe resolved callout number (1-indexed).
location: LocationSource location of this callout reference.
Implementations§
Trait Implementations§
Source§impl Clone for CalloutRef
impl Clone for CalloutRef
Source§fn clone(&self) -> CalloutRef
fn clone(&self) -> CalloutRef
Returns a duplicate of the value. Read more
1.0.0 · 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 CalloutRef
impl Debug for CalloutRef
Source§impl<'de> Deserialize<'de> for CalloutRef
impl<'de> Deserialize<'de> for CalloutRef
Source§fn deserialize<D>(deserializer: D) -> Result<CalloutRef, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<CalloutRef, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for CalloutRef
impl PartialEq for CalloutRef
Source§impl Serialize for CalloutRef
impl Serialize for CalloutRef
impl Eq for CalloutRef
impl StructuralPartialEq for CalloutRef
Auto Trait Implementations§
impl Freeze for CalloutRef
impl RefUnwindSafe for CalloutRef
impl Send for CalloutRef
impl Sync for CalloutRef
impl Unpin for CalloutRef
impl UnwindSafe for CalloutRef
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