[][src]Enum notedown_parser::AST

pub enum AST {
    None,
    Statements(Vec<AST, Global>),
    Header {
        level: usize,
        children: Vec<AST, Global>,
        r: TextRange,
    },
    HorizontalRule {
        r: TextRange,
    },
    Paragraph {
        children: Vec<AST, Global>,
        r: TextRange,
    },
    Highlight {
        lang: String,
        code: String,
        inline: bool,
        high_line: Vec<usize, Global>,
        r: TextRange,
    },
    MathBlock {
        inner: String,
        r: TextRange,
    },
    TableView {
        head: Vec<AST, Global>,
        align: Vec<Option<bool>, Global>,
        terms: Vec<Vec<AST, Global>, Global>,
        column: usize,
        r: TextRange,
    },
    QuoteList {
        style: Option<String>,
        body: Vec<AST, Global>,
        r: TextRange,
    },
    OrderedList {
        head: usize,
        body: Vec<AST, Global>,
        r: TextRange,
    },
    OrderlessList {
        body: Vec<AST, Global>,
        r: TextRange,
    },
    Normal {
        inner: String,
        r: TextRange,
    },
    Raw {
        inner: String,
        r: TextRange,
    },
    Code {
        inner: String,
        r: TextRange,
    },
    Italic {
        children: Vec<AST, Global>,
        r: TextRange,
    },
    Bold {
        children: Vec<AST, Global>,
        r: TextRange,
    },
    Emphasis {
        children: Vec<AST, Global>,
        r: TextRange,
    },
    Underline {
        children: Vec<AST, Global>,
        r: TextRange,
    },
    Strikethrough {
        children: Vec<AST, Global>,
        r: TextRange,
    },
    Undercover {
        children: Vec<AST, Global>,
        r: TextRange,
    },
    MathInline {
        inner: String,
        r: TextRange,
    },
    MathDisplay {
        inner: String,
        r: TextRange,
    },
    Link {
        inner: SmartLink,
        r: TextRange,
    },
    Escaped {
        inner: char,
        r: TextRange,
    },
    Command {
        cmd: String,
        kind: CommandKind,
        args: Vec<AST, Global>,
        kvs: HashMap<String, AST, RandomState>,
        r: TextRange,
    },
    String {
        inner: String,
        r: TextRange,
    },
    Integer {
        inner: String,
        r: TextRange,
    },
    Decimal {
        inner: String,
        r: TextRange,
    },
    Boolean {
        inner: bool,
        r: TextRange,
    },
    Array {
        inner: Vec<AST, Global>,
        r: TextRange,
    },
}

Variants

None
  • None: It doesn't look like anything to me
Statements(Vec<AST, Global>)
Header
  • Header: TEXT, level

Fields of Header

level: usizechildren: Vec<AST, Global>r: TextRange
HorizontalRule

Fields of HorizontalRule

r: TextRange
Paragraph
  • Paragraph:

Fields of Paragraph

children: Vec<AST, Global>r: TextRange
Highlight

Fields of Highlight

lang: Stringcode: Stringinline: boolhigh_line: Vec<usize, Global>r: TextRange
MathBlock
  • Math:

Fields of MathBlock

inner: Stringr: TextRange
TableView

Fields of TableView

head: Vec<AST, Global>align: Vec<Option<bool>, Global>terms: Vec<Vec<AST, Global>, Global>column: usizer: TextRange
QuoteList

Fields of QuoteList

style: Option<String>body: Vec<AST, Global>r: TextRange
OrderedList

Fields of OrderedList

head: usizebody: Vec<AST, Global>r: TextRange
OrderlessList

Fields of OrderlessList

body: Vec<AST, Global>r: TextRange
Normal
  • Code:

Fields of Normal

inner: Stringr: TextRange
Raw

Fields of Raw

inner: Stringr: TextRange
Code

`code`

Fields of Code

inner: Stringr: TextRange
Italic

Fields of Italic

children: Vec<AST, Global>r: TextRange
Bold

Fields of Bold

children: Vec<AST, Global>r: TextRange
Emphasis

Fields of Emphasis

children: Vec<AST, Global>r: TextRange
Underline

Fields of Underline

children: Vec<AST, Global>r: TextRange
Strikethrough

Fields of Strikethrough

children: Vec<AST, Global>r: TextRange
Undercover

Fields of Undercover

children: Vec<AST, Global>r: TextRange
MathInline

Fields of MathInline

inner: Stringr: TextRange
MathDisplay

Fields of MathDisplay

inner: Stringr: TextRange

Fields of Link

inner: SmartLinkr: TextRange
Escaped

Fields of Escaped

inner: charr: TextRange
Command

Fields of Command

cmd: Stringkind: CommandKindargs: Vec<AST, Global>kvs: HashMap<String, AST, RandomState>r: TextRange
String

Fields of String

inner: Stringr: TextRange
Integer

Fields of Integer

inner: Stringr: TextRange
Decimal

Fields of Decimal

inner: Stringr: TextRange
Boolean

Fields of Boolean

inner: boolr: TextRange
Array

Fields of Array

inner: Vec<AST, Global>r: TextRange

Implementations

impl AST[src]

pub fn to_vec(&self) -> Vec<AST, Global>[src]

impl AST[src]

pub fn toc(&self, max_depth: usize) -> TOC[src]

impl AST[src]

pub fn ask_element(&self, u32, u32)[src]

Trait Implementations

impl Clone for AST[src]

impl Debug for AST[src]

impl Default for AST[src]

impl Display for AST[src]

impl Eq for AST[src]

impl PartialEq<AST> for AST[src]

impl Slugify for AST[src]

impl StructuralEq for AST[src]

impl StructuralPartialEq for AST[src]

impl ToHTML for AST[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.