Base class for markdown block nodes that can contain other blocks.
Object
Namespace: Radzen.Blazor.Markdown
Assembly: Radzen.Blazor.dll
public abstract class BlockContainer : Markdown.Block, Markdown.INodeBase class for markdown block nodes that can contain other blocks.
protected BlockContainer()Returns the children of the block.
public IReadOnlyList<Markdown.Block> Children { get; }
| Type | Description |
|---|---|
| IReadOnlyList<Markdown.Block> | Returns the children of the block. |
public Markdown.Block FirstChild { get; }
| Type | Description |
|---|---|
| Markdown.Block |
public Markdown.Block LastChild { get; }
| Type | Description |
|---|---|
| Markdown.Block |
Appends a block to the children of the block.
public virtual Markdown.T Add(Markdown.T block)
| Type | Name | Description |
|---|---|---|
| Markdown.T | block | The block to add. |
| Type | Description |
|---|---|
| Markdown.T | The added block. |
Determines if the block can contain the specified node.
public virtual bool CanContain(Markdown.Block node)
| Type | Name | Description |
|---|---|---|
| Markdown.Block | node |
| Type | Description |
|---|---|
| bool |
Returns the next sibling of the block.
public Markdown.Block NextSibling(Markdown.Block block)
| Type | Name | Description |
|---|---|---|
| Markdown.Block | block | The block to get the next sibling of. |
| Type | Description |
|---|---|
| Markdown.Block | The next sibling of the block. |
Removes a block from the children of the block.
public void Remove(Markdown.Block block)
| Type | Name | Description |
|---|---|---|
| Markdown.Block | block | The block to remove. |
Replaces a block with another block.
public void Replace(Markdown.Block source, Markdown.Block target)
| Type | Name | Description |
|---|---|---|
| Markdown.Block | source | The block to replace. |
| Markdown.Block | target | The block to replace with. |