pub struct CompositeTransformer { /* private fields */ }Expand description
Composite transformer that applies multiple transformers in sequence
Implementations§
Source§impl CompositeTransformer
impl CompositeTransformer
Sourcepub fn add_transformer<T: Transformer + 'static>(self, transformer: T) -> Self
pub fn add_transformer<T: Transformer + 'static>(self, transformer: T) -> Self
Add a transformer to the sequence
Trait Implementations§
Source§impl Default for CompositeTransformer
impl Default for CompositeTransformer
Source§impl Transformer for CompositeTransformer
impl Transformer for CompositeTransformer
Source§fn transform_document(&mut self, doc: Document) -> Document
fn transform_document(&mut self, doc: Document) -> Document
Transform a document node
Source§fn transform_block(&mut self, block: Block) -> Block
fn transform_block(&mut self, block: Block) -> Block
Transform a block node
Source§fn transform_inline(&mut self, inline: Inline) -> Inline
fn transform_inline(&mut self, inline: Inline) -> Inline
Transform an inline node
Source§fn transform_table_cell(&mut self, cell: TableCell) -> TableCell
fn transform_table_cell(&mut self, cell: TableCell) -> TableCell
Transform a table cell
Source§fn transform_list_item(&mut self, item: ListItem) -> ListItem
fn transform_list_item(&mut self, item: ListItem) -> ListItem
Transform a list item
Source§fn transform_table_row(&mut self, row: TableRow) -> TableRow
fn transform_table_row(&mut self, row: TableRow) -> TableRow
Transform a table row
Source§fn transform_heading(&mut self, heading: Heading) -> Heading
fn transform_heading(&mut self, heading: Heading) -> Heading
Transform a heading
Source§fn transform_link(&mut self, link: Link) -> Link
fn transform_link(&mut self, link: Link) -> Link
Transform a link
Source§fn transform_image(&mut self, image: Image) -> Image
fn transform_image(&mut self, image: Image) -> Image
Transform an image
Source§fn transform_code_block(&mut self, code_block: CodeBlock) -> CodeBlock
fn transform_code_block(&mut self, code_block: CodeBlock) -> CodeBlock
Transform a code block
Source§fn transform_text(&mut self, text: String) -> String
fn transform_text(&mut self, text: String) -> String
Transform text content
Source§fn transform_footnote_definition(
&mut self,
footnote: FootnoteDefinition,
) -> FootnoteDefinition
fn transform_footnote_definition( &mut self, footnote: FootnoteDefinition, ) -> FootnoteDefinition
Transform a footnote definition
Source§fn transform_github_alert(&mut self, alert: GitHubAlert) -> GitHubAlert
fn transform_github_alert(&mut self, alert: GitHubAlert) -> GitHubAlert
Transform a GitHub alert
Source§fn walk_transform_document(&mut self, doc: Document) -> Document
fn walk_transform_document(&mut self, doc: Document) -> Document
Default transformation for document
Source§fn walk_transform_block(&mut self, block: Block) -> Block
fn walk_transform_block(&mut self, block: Block) -> Block
Default transformation for block nodes
Source§fn walk_transform_inline(&mut self, inline: Inline) -> Inline
fn walk_transform_inline(&mut self, inline: Inline) -> Inline
Default transformation for inline nodes
Source§fn walk_transform_table_cell(&mut self, cell: TableCell) -> TableCell
fn walk_transform_table_cell(&mut self, cell: TableCell) -> TableCell
Default transformation for table cells
Source§fn walk_transform_list_item(&mut self, item: ListItem) -> ListItem
fn walk_transform_list_item(&mut self, item: ListItem) -> ListItem
Default transformation for list items
Source§fn walk_transform_table_row(&mut self, row: TableRow) -> TableRow
fn walk_transform_table_row(&mut self, row: TableRow) -> TableRow
Default transformation for table rows
Source§fn walk_transform_heading(&mut self, heading: Heading) -> Heading
fn walk_transform_heading(&mut self, heading: Heading) -> Heading
Default transformation for headings
Source§fn walk_transform_link(&mut self, link: Link) -> Link
fn walk_transform_link(&mut self, link: Link) -> Link
Default transformation for links
Source§fn walk_transform_image(&mut self, image: Image) -> Image
fn walk_transform_image(&mut self, image: Image) -> Image
Default transformation for images
Source§fn walk_transform_code_block(&mut self, code_block: CodeBlock) -> CodeBlock
fn walk_transform_code_block(&mut self, code_block: CodeBlock) -> CodeBlock
Default transformation for code blocks
Source§fn walk_transform_text(&mut self, text: String) -> String
fn walk_transform_text(&mut self, text: String) -> String
Default transformation for text
Source§fn expand_document(&mut self, doc: Document) -> Vec<Document>
fn expand_document(&mut self, doc: Document) -> Vec<Document>
Transform a document with possibility to expand into multiple documents Read more
Source§fn expand_block(&mut self, block: Block) -> Vec<Block>
fn expand_block(&mut self, block: Block) -> Vec<Block>
Transform a block with possibility to expand into multiple blocks Read more
Source§fn expand_inline(&mut self, inline: Inline) -> Vec<Inline>
fn expand_inline(&mut self, inline: Inline) -> Vec<Inline>
Transform an inline with possibility to expand into multiple inlines Read more
Source§fn expand_table_cell(&mut self, cell: TableCell) -> Vec<TableCell> ⓘ
fn expand_table_cell(&mut self, cell: TableCell) -> Vec<TableCell> ⓘ
Transform a table cell with possibility to expand into multiple cells
Source§fn expand_list_item(&mut self, item: ListItem) -> Vec<ListItem>
fn expand_list_item(&mut self, item: ListItem) -> Vec<ListItem>
Transform a list item with possibility to expand into multiple items
Source§fn expand_table_row(&mut self, row: TableRow) -> Vec<TableRow> ⓘ
fn expand_table_row(&mut self, row: TableRow) -> Vec<TableRow> ⓘ
Transform a table row with possibility to expand into multiple rows
Source§fn expand_heading(&mut self, heading: Heading) -> Vec<Heading>
fn expand_heading(&mut self, heading: Heading) -> Vec<Heading>
Transform a heading with possibility to expand into multiple headings
Source§fn expand_link(&mut self, link: Link) -> Vec<Link>
fn expand_link(&mut self, link: Link) -> Vec<Link>
Transform a link with possibility to expand into multiple links
Source§fn expand_image(&mut self, image: Image) -> Vec<Image>
fn expand_image(&mut self, image: Image) -> Vec<Image>
Transform an image with possibility to expand into multiple images
Source§fn expand_code_block(&mut self, code_block: CodeBlock) -> Vec<CodeBlock>
fn expand_code_block(&mut self, code_block: CodeBlock) -> Vec<CodeBlock>
Transform a code block with possibility to expand into multiple code blocks
Source§fn expand_text(&mut self, text: String) -> Vec<String>
fn expand_text(&mut self, text: String) -> Vec<String>
Transform text with possibility to expand into multiple text strings
Source§fn expand_footnote_definition(
&mut self,
footnote: FootnoteDefinition,
) -> Vec<FootnoteDefinition>
fn expand_footnote_definition( &mut self, footnote: FootnoteDefinition, ) -> Vec<FootnoteDefinition>
Transform a footnote definition with possibility to expand into multiple definitions
Source§fn expand_github_alert(&mut self, alert: GitHubAlert) -> Vec<GitHubAlert>
fn expand_github_alert(&mut self, alert: GitHubAlert) -> Vec<GitHubAlert>
Transform a GitHub alert with possibility to expand into multiple alerts
Source§fn walk_expand_document(&mut self, doc: Document) -> Vec<Document>
fn walk_expand_document(&mut self, doc: Document) -> Vec<Document>
Walk document with expandable transformations Read more
Source§fn walk_expand_block(&mut self, block: Block) -> Vec<Block>
fn walk_expand_block(&mut self, block: Block) -> Vec<Block>
Walk block with expandable transformations Read more
Source§fn walk_expand_inline(&mut self, inline: Inline) -> Vec<Inline>
fn walk_expand_inline(&mut self, inline: Inline) -> Vec<Inline>
Walk inline with expandable transformations Read more
Source§fn walk_expand_table_cell(&mut self, cell: TableCell) -> Vec<TableCell> ⓘ
fn walk_expand_table_cell(&mut self, cell: TableCell) -> Vec<TableCell> ⓘ
Walk table cell with expandable transformations
Source§fn walk_expand_list_item(&mut self, item: ListItem) -> Vec<ListItem>
fn walk_expand_list_item(&mut self, item: ListItem) -> Vec<ListItem>
Walk list item with expandable transformations
Source§fn walk_expand_table_row(&mut self, row: TableRow) -> Vec<TableRow> ⓘ
fn walk_expand_table_row(&mut self, row: TableRow) -> Vec<TableRow> ⓘ
Walk table row with expandable transformations
Source§fn walk_expand_heading(&mut self, heading: Heading) -> Vec<Heading>
fn walk_expand_heading(&mut self, heading: Heading) -> Vec<Heading>
Walk heading with expandable transformations
Source§fn walk_expand_link(&mut self, link: Link) -> Vec<Link>
fn walk_expand_link(&mut self, link: Link) -> Vec<Link>
Walk link with expandable transformations
Source§fn walk_expand_image(&mut self, image: Image) -> Vec<Image>
fn walk_expand_image(&mut self, image: Image) -> Vec<Image>
Walk image with expandable transformations
Source§fn walk_expand_code_block(&mut self, code_block: CodeBlock) -> Vec<CodeBlock>
fn walk_expand_code_block(&mut self, code_block: CodeBlock) -> Vec<CodeBlock>
Walk code block with expandable transformations
Source§fn walk_expand_text(&mut self, text: String) -> Vec<String>
fn walk_expand_text(&mut self, text: String) -> Vec<String>
Walk text with expandable transformations
Source§fn walk_expand_footnote_definition(
&mut self,
footnote: FootnoteDefinition,
) -> Vec<FootnoteDefinition>
fn walk_expand_footnote_definition( &mut self, footnote: FootnoteDefinition, ) -> Vec<FootnoteDefinition>
Walk footnote definition with expandable transformations
Source§fn walk_expand_github_alert(&mut self, alert: GitHubAlert) -> Vec<GitHubAlert>
fn walk_expand_github_alert(&mut self, alert: GitHubAlert) -> Vec<GitHubAlert>
Walk GitHub alert with expandable transformations
Source§fn walk_transform_footnote_definition(
&mut self,
footnote: FootnoteDefinition,
) -> FootnoteDefinition
fn walk_transform_footnote_definition( &mut self, footnote: FootnoteDefinition, ) -> FootnoteDefinition
Default transformation for footnote definitions
Source§fn walk_transform_github_alert(&mut self, alert: GitHubAlert) -> GitHubAlert
fn walk_transform_github_alert(&mut self, alert: GitHubAlert) -> GitHubAlert
Default transformation for GitHub alerts
Auto Trait Implementations§
impl Freeze for CompositeTransformer
impl !RefUnwindSafe for CompositeTransformer
impl !Send for CompositeTransformer
impl !Sync for CompositeTransformer
impl Unpin for CompositeTransformer
impl !UnwindSafe for CompositeTransformer
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