menu

WinForms

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

    Show / Hide Table of Contents

    Class LabelCollection

    A collection of Label objects.

    Inheritance
    System.Object
    CollectionEx
    LabelCollection
    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.OnChanging(CollectionExEventArgs)
    CollectionEx.Owner
    CollectionEx.ProvideServiceReference(RuntimeTypeHandle)
    CollectionEx.QuietMode
    CollectionEx.RaiseChangingEvent(CollectionExEventArgs)
    CollectionEx.RemoveAt(Int32)
    CollectionEx.RemoveRange(ICollection)
    CollectionEx.RemoveValue(Object)
    CollectionEx.Set(Int32, Object)
    CollectionEx.Sort(IComparer)
    CollectionEx.SyncRoot
    CollectionEx.UpdateReferences
    CollectionEx.UpdateServiceReferences(CollectionExEventArgs)
    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 LabelCollection : CollectionEx, IList, ICollection, IEnumerable, ICloneable, ISerializable, IServiceReferenceHolder, IServiceReferenceProvider
    Remarks

    Label

    Constructors

    LabelCollection()

    Initializes a new instance of the LabelCollection class.

    Declaration
    public LabelCollection()

    LabelCollection(LabelCollection)

    Initializes a new instance of the LabelCollection class.

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

    The label collection.

    LabelCollection(Node)

    Initializes a new instance of the LabelCollection class.

    Declaration
    public LabelCollection(Node owner)
    Parameters
    Type Name Description
    Node owner

    The owner.

    LabelCollection(SerializationInfo, StreamingContext)

    Initializes a new instance of the LabelCollection class.

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

    The info.

    System.Runtime.Serialization.StreamingContext context

    The context.

    Properties

    Container

    Gets or sets the container.

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

    The container.

    Item[Int32]

    Gets or sets the Label at the specified index.

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

    The index.

    Property Value
    Type Description
    Label

    The label at the specified index.

    Item[String]

    Gets or sets the Label with the specified STR label name.

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

    The index

    Property Value
    Type Description
    Label

    The label at the specified index.

    Methods

    Add(Label)

    Adds the specified label.

    Declaration
    public int Add(Label label)
    Parameters
    Type Name Description
    Label label

    The label.

    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(Label)

    Determines whether the member contains the specified label.

    Declaration
    public bool Contains(Label label)
    Parameters
    Type Name Description
    Label label

    The label.

    Returns
    Type Description
    System.Boolean

    true if it contains the specified label; otherwise, false.

    Contains(String)

    Determines specified label name.

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

    Name of the label.

    Returns
    Type Description
    System.Boolean

    true if the specified STR label name is available; otherwise, false.

    CopyTo(Label[], Int32)

    Copies the labels collection to the specified index.

    Declaration
    public void CopyTo(Label[] labels, int index)
    Parameters
    Type Name Description
    Label[] labels

    The labels.

    System.Int32 index

    The index.

    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(Label)

    Returns the index of the label.

    Declaration
    public int IndexOf(Label label)
    Parameters
    Type Name Description
    Label label

    The label.

    Returns
    Type Description
    System.Int32

    The value.

    Insert(Int32, Label)

    Inserts label at the specified index.

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

    The index.

    Label label

    The label.

    OnChangesComplete(CollectionExEventArgs)

    Raises the ChangesComplete event.

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

    The CollectionExEventArgs instance containing the event data.

    Overrides
    CollectionEx.OnChangesComplete(CollectionExEventArgs)

    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)

    Remove(Label)

    Removes the specified label.

    Declaration
    public void Remove(Label label)
    Parameters
    Type Name Description
    Label label

    The label.

    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