pub enum Line<'a> {
Normal(Composite<'a>),
TableRow(TableRow<'a>),
TableRule(TableRule),
HorizontalRule,
CodeFence(Composite<'a>),
}
Expand description
a parsed line
Variants§
Normal(Composite<'a>)
TableRow(TableRow<'a>)
TableRule(TableRule)
HorizontalRule
CodeFence(Composite<'a>)
Implementations§
source§impl<'a> Line<'a>
impl<'a> Line<'a>
pub fn from(md: &'a str) -> Self
pub fn raw_str(s: &'a str) -> Self
pub fn char_length(&self) -> usize
pub fn new_paragraph(compounds: Vec<Compound<'_>>) -> Line<'_>
pub fn empty_code_fence() -> Line<'static>
pub fn new_code_fence(compounds: Vec<Compound<'_>>) -> Line<'_>
pub fn new_code(compound: Compound<'_>) -> Line<'_>
pub fn new_quote(compounds: Vec<Compound<'_>>) -> Line<'_>
pub fn new_list_item(depth: u8, compounds: Vec<Compound<'_>>) -> Line<'_>
pub fn new_header(level: u8, compounds: Vec<Compound<'_>>) -> Line<'_>
pub fn new_table_row(cells: Vec<Composite<'_>>) -> Line<'_>
pub fn new_table_alignments(cells: Vec<Alignment>) -> Line<'static>
pub fn is_table_row(&self) -> bool
pub fn is_table_part(&self) -> bool
pub fn is_code(&self) -> bool
Trait Implementations§
source§impl<'a> PartialEq for Line<'a>
impl<'a> PartialEq for Line<'a>
impl<'a> Eq for Line<'a>
impl<'a> StructuralPartialEq for Line<'a>
Auto Trait Implementations§
impl<'a> Freeze for Line<'a>
impl<'a> RefUnwindSafe for Line<'a>
impl<'a> Send for Line<'a>
impl<'a> Sync for Line<'a>
impl<'a> Unpin for Line<'a>
impl<'a> UnwindSafe for Line<'a>
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