src/Markdig/Renderers/RendererBase.cs
/// <summary>
/// Writes the children of the specified <see cref="ContainerBlock"/>.
/// </summary>
/// <param name="containerBlock">The container block.</param>
Writes the children of the specified .
Writes the children of the specified .
public void WriteChildren(ContainerBlock containerBlock)
        {
            if (containerBlock is null)
            {
                return;
            }
            ThrowHelper.CheckDepthLimit(childrenDepth++);
            bool saveIsFirstInContainer = IsFirstInContainer;
            bool saveIsLastInContainer = IsLastInContainer;
            var children = containerBlock;
            for (int i = 0; i < children.Count; i++)
            {
                IsFirstInContainer = i == 0;
                IsLastInContainer = i + 1 == children.Count;
                Write(children[i]);
            }
            IsFirstInContainer = saveIsFirstInContainer;
            IsLastInContainer = saveIsLastInContainer;
            childrenDepth--;
        }
public void WriteChildren ( ContainerBlock containerBlock ) { if ( containerBlock is null ) { return ; } ThrowHelper . CheckDepthLimit ( childrenDepth ++ ) ; bool saveIsFirstInContainer = IsFirstInContainer ; bool saveIsLastInContainer = IsLastInContainer ; var children = containerBlock ; for ( int i = 0 ; i < children . Count ; i ++ ) { IsFirstInContainer = i == 0 ; IsLastInContainer = i + 1 == children . Count ; Write ( children [ i ] ) ; } IsFirstInContainer = saveIsFirstInContainer ; IsLastInContainer = saveIsLastInContainer ; childrenDepth -- ; }
Writes the children of the specified .
Writes the children of the specified .
containerBlock
ContainerBlock
The container block.
The container block .