menu

WinForms

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class NodeCollection - WindowsForms API Reference | Syncfusion

    Show / Hide Table of Contents

    Class NodeCollection

    A collection of Node objects.

    Inheritance
    System.Object
    CollectionEx
    NodeCollection
    ClipboardNodeCollection
    Implements
    System.Collections.IList
    System.Collections.ICollection
    System.Collections.IEnumerable
    System.ICloneable
    System.Runtime.Serialization.ISerializable
    IServiceReferenceHolder
    IServiceReferenceProvider
    Inherited Members
    CollectionEx.AddRange(ICollection)
    CollectionEx.AddValue(Object)
    CollectionEx.Clear()
    CollectionEx.CopyTo(Array, Int32)
    CollectionEx.Count
    CollectionEx.EventSink
    CollectionEx.GetObjectData(SerializationInfo, StreamingContext)
    CollectionEx.IEnumerable.GetEnumerator()
    CollectionEx.IList.Add(Object)
    CollectionEx.IList.Clear()
    CollectionEx.IList.Contains(Object)
    CollectionEx.IList.get_Item(Int32)
    CollectionEx.IList.IndexOf(Object)
    CollectionEx.IList.Insert(Int32, Object)
    CollectionEx.IList.IsFixedSize
    CollectionEx.IList.IsReadOnly
    CollectionEx.IList.Item[Int32]
    CollectionEx.IList.Remove(Object)
    CollectionEx.IList.RemoveAt(Int32)
    CollectionEx.IList.set_Item(Int32, Object)
    CollectionEx.InsertValue(Int32, Object)
    CollectionEx.IsEmpty
    CollectionEx.IsSynchronized
    CollectionEx.Members
    CollectionEx.OnChangesComplete(CollectionExEventArgs)
    CollectionEx.OnChanging(CollectionExEventArgs)
    CollectionEx.Owner
    CollectionEx.ProvideServiceReference(RuntimeTypeHandle)
    CollectionEx.QuietMode
    CollectionEx.RemoveAt(Int32)
    CollectionEx.RemoveRange(ICollection)
    CollectionEx.RemoveValue(Object)
    CollectionEx.Set(Int32, Object)
    CollectionEx.Sort(IComparer)
    CollectionEx.SyncRoot
    CollectionEx.UpdateReferences
    CollectionEx.UpdateServiceReferences(IServiceReferenceProvider)
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Syncfusion.Windows.Forms.Diagram
    Assembly: Syncfusion.Diagram.Base.dll
    Syntax
    public class NodeCollection : CollectionEx, IList, ICollection, IEnumerable, ICloneable, ISerializable, IServiceReferenceHolder, IServiceReferenceProvider

    Constructors

    NodeCollection()

    Initializes a new instance of the NodeCollection class.

    Declaration
    public NodeCollection()

    NodeCollection(NodeCollection)

    Initializes a new instance of the NodeCollection class.

    Declaration
    public NodeCollection(NodeCollection src)
    Parameters
    Type Name Description
    NodeCollection src

    The node collection

    NodeCollection(NodeCollection, Boolean)

    Initializes a new instance of the NodeCollection class.

    Declaration
    public NodeCollection(NodeCollection src, bool cloning)
    Parameters
    Type Name Description
    NodeCollection src

    The node collection

    System.Boolean cloning

    Clone the collection.

    NodeCollection(Object)

    Initializes a new instance of the NodeCollection class.

    Declaration
    public NodeCollection(object owner)
    Parameters
    Type Name Description
    System.Object owner

    The owner.

    NodeCollection(SerializationInfo, StreamingContext)

    Initializes a new instance of the NodeCollection class.

    Declaration
    public NodeCollection(SerializationInfo info, StreamingContext context)
    Parameters
    Type Name Description
    System.Runtime.Serialization.SerializationInfo info

    The info.

    System.Runtime.Serialization.StreamingContext context

    The context.

    Fields

    c_strNODE

    Name of the node.

    Declaration
    protected const string c_strNODE = "Node"
    Field Value
    Type
    System.String

    Properties

    Container

    Gets or sets the container.

    Declaration
    public object Container { get; set; }
    Property Value
    Type Description
    System.Object

    The container.

    First

    Gets or sets the first item in collection.

    Declaration
    public Node First { get; set; }
    Property Value
    Type Description
    Node

    The first.

    Exceptions
    Type Condition
    System.ArgumentOutOfRangeException

    If collection count less than 1.

    Item[Int32]

    Gets or sets the Node at the specified index.

    Declaration
    public Node this[int index] { get; set; }
    Parameters
    Type Name Description
    System.Int32 index

    The index.

    Property Value
    Type Description
    Node

    The node

    Item[String]

    Gets or sets the Node with the specified node name.

    Declaration
    public Node this[string strNodeName] { get; set; }
    Parameters
    Type Name Description
    System.String strNodeName

    Node name.

    Property Value
    Type Description
    Node

    The node with the specified name.

    Last

    Gets or sets the last item in collection.

    Declaration
    public Node Last { get; set; }
    Property Value
    Type Description
    Node

    The last.

    Exceptions
    Type Condition
    System.ArgumentOutOfRangeException

    If collection count less than 1.

    Methods

    Add(Node)

    Adds an node to the end of the NodeCollection.

    Declaration
    public int Add(Node node)
    Parameters
    Type Name Description
    Node node

    The node to add.

    Returns
    Type Description
    System.Int32

    The value

    Clone()

    Creates a new object that is a copy of the current instance.

    Declaration
    public override object Clone()
    Returns
    Type Description
    System.Object

    A new object that is a copy of this instance.

    Overrides
    CollectionEx.Clone()

    Contains(Node)

    Determines whether NodeCollection contains the specified node.

    Declaration
    public bool Contains(Node node)
    Parameters
    Type Name Description
    Node node

    The node.

    Returns
    Type Description
    System.Boolean

    true if NodeCollection contains the specified node; otherwise, false.

    Contains(String)

    Determines whether NodeCollection contains the node with specified name.

    Declaration
    public bool Contains(string strNodeName)
    Parameters
    Type Name Description
    System.String strNodeName

    Name of the node.

    Returns
    Type Description
    System.Boolean

    true if NodeCollection contains the node with specified name; otherwise, false.

    CopyTo(Node[], Int32)

    Copies the entire NodeCollection to a compatible one-dimensional System.Array, starting at the beginning of the target array.

    Declaration
    public void CopyTo(Node[] nodes, int index)
    Parameters
    Type Name Description
    Node[] nodes

    The one-dimensional array that is the destination of the elements copied from NodeCollection.

    System.Int32 index

    is equal to or greater than the length of nodes.

    FindNodeByName(String)

    Finds the node by unique name.

    Declaration
    public Node FindNodeByName(string strNodeName)
    Parameters
    Type Name Description
    System.String strNodeName

    Name of the node.

    Returns
    Type Description
    Node

    The node.

    GenerateUniqueName(Node)

    Generates the unique node name.

    Declaration
    protected string GenerateUniqueName(Node node)
    Parameters
    Type Name Description
    Node node

    The node.

    Returns
    Type Description
    System.String

    The unique name.

    GetEnumerator()

    Returns an enumerator that iterates through a collection.

    Declaration
    public override IEnumerator GetEnumerator()
    Returns
    Type Description
    System.Collections.IEnumerator

    An System.Collections.IEnumerator object that can be used to iterate through the collection.

    Overrides
    CollectionEx.GetEnumerator()

    IndexOf(Node)

    Searches for the specified node and returns the zero-based index of the first occurrence within the entire NodeCollection.

    Declaration
    public int IndexOf(Node node)
    Parameters
    Type Name Description
    Node node

    The node.

    Returns
    Type Description
    System.Int32

    The zero-based index of the first occurrence of node within the entire NodeCollection, if found; otherwise, -1.

    Insert(Int32, Node)

    Inserts an element into the NodeCollection.

    Declaration
    public void Insert(int index, Node node)
    Parameters
    Type Name Description
    System.Int32 index

    The zero-based starting index of the search.

    Node node

    The node to locate in the NodeCollection.

    OnValidate(ICollection)

    Validates given values.

    Declaration
    protected override void OnValidate(ICollection values)
    Parameters
    Type Name Description
    System.Collections.ICollection values

    The values to validate.

    Overrides
    CollectionEx.OnValidate(ICollection)
    Exceptions
    Type Condition
    System.InvalidCastException

    OnValidate(Object)

    Validates given value.

    Declaration
    protected override void OnValidate(object value)
    Parameters
    Type Name Description
    System.Object value

    value to validate

    Overrides
    CollectionEx.OnValidate(Object)
    Exceptions
    Type Condition
    System.InvalidCastException

    RaiseChangesCompleteEvent(CollectionExEventArgs)

    Raises ChangesComplete event.

    Declaration
    protected override void RaiseChangesCompleteEvent(CollectionExEventArgs evtArgs)
    Parameters
    Type Name Description
    CollectionExEventArgs evtArgs

    event args

    Overrides
    CollectionEx.RaiseChangesCompleteEvent(CollectionExEventArgs)

    RaiseChangingEvent(CollectionExEventArgs)

    Raise Changing event.

    Declaration
    protected override void RaiseChangingEvent(CollectionExEventArgs evtArgs)
    Parameters
    Type Name Description
    CollectionExEventArgs evtArgs

    event args

    Overrides
    CollectionEx.RaiseChangingEvent(CollectionExEventArgs)

    Remove(Node)

    Removes the first occurrence of a specific node from the NodeCollection.

    Declaration
    public bool Remove(Node node)
    Parameters
    Type Name Description
    Node node

    The node.

    Returns
    Type Description
    System.Boolean

    true, if remove the node, false otherwise.

    Remove(NodeCollection)

    Removes a range of elements from the NodeCollection.

    Declaration
    public void Remove(NodeCollection nodes)
    Parameters
    Type Name Description
    NodeCollection nodes

    The nodes.

    UpdateServiceReferences(CollectionExEventArgs)

    Updates the service references the collection members.

    Declaration
    protected override void UpdateServiceReferences(CollectionExEventArgs evtArgs)
    Parameters
    Type Name Description
    CollectionExEventArgs evtArgs

    The CollectionExEventArgs instance containing the event data.

    Overrides
    CollectionEx.UpdateServiceReferences(CollectionExEventArgs)

    Implements

    System.Collections.IList
    System.Collections.ICollection
    System.Collections.IEnumerable
    System.ICloneable
    System.Runtime.Serialization.ISerializable
    IServiceReferenceHolder
    IServiceReferenceProvider

    Extension Methods

    EnumerableExtensions.GetElementType(IEnumerable)
    EnumerableExtensions.GetItemPropertyInfo(IEnumerable)
    FunctionalExtensions.ForEach<T>(IEnumerable, Action<T>)
    FunctionalExtensions.ToList<T>(IEnumerable)
    FunctionalExtensions.MoveTo(IList, Int32, Int32)
    QueryableExtensions.OfQueryable(IEnumerable)
    QueryableExtensions.OfQueryable(IEnumerable, Type)
    QueryableExtensions.GroupByMany<TElement>(IEnumerable, Type, List<Func<TElement, Object>>)
    QueryableExtensions.GroupByMany(IEnumerable, Type, Func<String, Expression>, String[])
    QueryableExtensions.GroupByMany(IEnumerable, Type, List<SortDescriptor>, Dictionary<String, IComparer<Object>>, Func<String, Expression>, String[])
    QueryableExtensions.GroupByMany(IEnumerable, Type, List<SortDescriptor>, Func<String, Expression>, String[])
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved