Demos About Radzen
Search Results for

    Show / Hide Table of Contents

    Class BlockContainer

    Base class for markdown block nodes that can contain other blocks.

    Inheritance
    System.Object
    Block
    BlockContainer
    BlockQuote
    Document
    List
    ListItem
    Implements
    INode
    Inherited Members
    Block.Accept(INodeVisitor)
    Block.Next
    Block.Parent
    Block.Remove()
    Namespace: Radzen.Blazor.Markdown
    Assembly: Radzen.Blazor.dll
    Syntax
    public abstract class BlockContainer : Block, INode

    Properties

    Children

    Returns the children of the block.

    Declaration
    public IReadOnlyList<Block> Children { get; }
    Property Value
    Type Description
    IReadOnlyList<Block>

    FirstChild

    Returns the first child of the block.

    Declaration
    public override Block FirstChild { get; }
    Property Value
    Type Description
    Block
    Overrides
    Block.FirstChild

    LastChild

    Returns the last child of the block.

    Declaration
    public override Block LastChild { get; }
    Property Value
    Type Description
    Block
    Overrides
    Block.LastChild

    Methods

    Add<T>(T)

    Appends a block to the children of the block.

    Declaration
    public virtual T Add<T>(T block)
        where T : Block
    Parameters
    Type Name Description
    T block

    The block to add.

    Returns
    Type Description
    T

    The added block.

    Type Parameters
    Name Description
    T

    The type of the block.

    CanContain(Block)

    Determines if the block can contain the specified node.

    Declaration
    public virtual bool CanContain(Block node)
    Parameters
    Type Name Description
    Block node
    Returns
    Type Description
    System.Boolean

    NextSibling(Block)

    Returns the next sibling of the block.

    Declaration
    public Block NextSibling(Block block)
    Parameters
    Type Name Description
    Block block

    The block to get the next sibling of.

    Returns
    Type Description
    Block

    The next sibling of the block.

    Remove(Block)

    Removes a block from the children of the block.

    Declaration
    public void Remove(Block block)
    Parameters
    Type Name Description
    Block block

    The block to remove.

    Replace(Block, Block)

    Replaces a block with another block.

    Declaration
    public void Replace(Block source, Block target)
    Parameters
    Type Name Description
    Block source

    The block to replace.

    Block target

    The block to replace with.

    Implements

    INode

    Introducing Radzen Blazor Studio

    Radzen Blazor Studio is a software development environment that empowers developers to design, build and deploy Blazor applications without the traditional hurdles. Write less code and get more done.

    Learn More

    Download Now
    Download Now
    In This Article
    Back to top Radzen Blazor Components, © 2018-2025 Radzen. Source Code licensed under MIT