pub enum BlockKind {
Show 13 variants
Prose,
BulletList,
NumberedList,
Table,
Code,
Blockquote,
Image,
Region,
Html,
ThematicBreak,
References,
Group,
Heading,
}Expand description
One variant per grammar block.kind value.
Variants§
Prose
Paragraphs.
BulletList
A bullet list.
NumberedList
An ordered list.
Table
A GFM table.
Code
A code block.
Blockquote
A block quote.
Image
A paragraph of images only.
Region
The host’s region: a block its open and close markers bound.
Html
An HTML block.
ThematicBreak
A horizontal rule.
References
Link reference definitions at the top level of the body, outside the generated block.
Group
A repeating sequence of blocks; matched by the checker, never parsed.
Heading
A heading inside an item or a quote, which is no heading of the document; parsed, and named by no schema.
Implementations§
Source§impl BlockKind
impl BlockKind
Sourcepub fn name(self) -> &'static str
pub fn name(self) -> &'static str
The grammar’s name for the kind, the host’s region as region.
Sourcepub fn name_in(self, dialect: &Dialect) -> &'static str
pub fn name_in(self, dialect: &Dialect) -> &'static str
The grammar’s name for the kind, the host’s region by the name its dialect gives it.
Trait Implementations§
impl Copy for BlockKind
Source§impl<'de> Deserialize<'de> for BlockKind
impl<'de> Deserialize<'de> for BlockKind
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<BlockKind, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<BlockKind, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for BlockKind
Source§impl Serialize for BlockKind
impl Serialize for BlockKind
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for BlockKind
Auto Trait Implementations§
impl Forget for BlockKind
impl Freeze for BlockKind
impl Move for BlockKind
impl RefUnwindSafe for BlockKind
impl Send for BlockKind
impl Sync for BlockKind
impl Unpin for BlockKind
impl UnsafeUnpin for BlockKind
impl UnwindSafe for BlockKind
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.