pub enum Segment {
Html(String),
Deferred {
node_type: String,
attrs_json: String,
child_types: Vec<String>,
content: Vec<Segment>,
},
}Expand description
One piece of renderer output. Html is finished markup; Deferred is a
callback node whose markup the caller supplies after the render, carrying
everything needed to produce it. Content nests, so callback nodes inside
callback nodes resolve depth-first. child_types lists the node’s
element/block children by type, in document order — structural facts a
callback can’t recover from attrs or the rendered content (an image
count, whether a list item holds a nested list).
Variants§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Segment
impl RefUnwindSafe for Segment
impl Send for Segment
impl Sync for Segment
impl Unpin for Segment
impl UnsafeUnpin for Segment
impl UnwindSafe for Segment
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