pub struct LineParser<'s> { /* private fields */ }
Expand description

The structure parsing a line or part of a line. A LineParser initialized from a markdown string exposes 2 main methods:

  • line parses a line which is supposed to be part of a markdown text. This method shouln’t really be used externally: a text can be parsed in a whole using Text::from
  • inline parses a snippet which isn’t supposed to be part of a markdown text. Some types of lines aren’t produced this ways as they don’t make sense out of a text: ListItem, TableRow, Code.

Normally not used directly but though line::from(str)

Implementations

should be called when the line must be interpreted as a code part, for example between code fences

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.