src/GenFx.Components/Trees/TreeNode.cs
/// <summary>
/// Inserts the <paramref name="node"/> in the list of child nodes at the position specified.
/// </summary>
/// <param name="index">Position in the list of child nodes where the <paramref name="node"/> is to be inserted.</param>
/// <param name="node"><see cref="TreeNode"/> to insert.</param>
/// <exception cref="ArgumentOutOfRangeException"><paramref name="index"/> is less than zero or greater than the number of child nodes.</exception>
/// <exception cref="ArgumentNullException"><paramref name="node"/> is null.</exception>
/// <exception cref="InvalidOperationException">Tree has not been set.</exception>
Inserts the  in the list of child nodes at the position specified.
Inserts the in the list of child nodes at the position specified .
protected virtual void InsertChildCore(int index, TreeNode node)
        {
            if (node is null)
            {
                throw new ArgumentNullException(nameof(node));
            }
            if (this.tree is null)
            {
                throw new InvalidOperationException(
                  StringUtil.GetFormattedString(Resources.ErrorMsg_InsertChildNodeWithoutTree));
            }
            this.childNodes.Insert(index, node);
            node.ParentNode = this;
            node.Tree = this.tree;
            TreeHelper.SetTreeForChildNodes(node);
        }
protected virtual void InsertChildCore ( int index , TreeNode node ) { if ( node is null ) { throw new ArgumentNullException ( nameof ( node ) ) ; } if ( this . tree is null ) { throw new InvalidOperationException ( StringUtil . GetFormattedString ( Resources . ErrorMsg_InsertChildNodeWithoutTree ) ) ; } this . childNodes . Insert ( index , node ) ; node . ParentNode = this ; node . Tree = this . tree ; TreeHelper . SetTreeForChildNodes ( node ) ; }
Inserts the  in the list of child nodes at the position specified.
Inserts the in the list of child nodes at the position specified .
None
None
Tree has not been set.
Tree has not been set .
index
int
Position in the list of child nodes where the  is to be inserted.
Position in the list of child nodes where the is to be inserted .
node
TreeNode
None