Class
RadItemReadOnlyCollection

Definition

Namespace:Telerik.WinControls.Elements

Assembly:Telerik.WinControls.dll

Syntax:

cs-api-definition
[ListBindable(false)]
public class RadItemReadOnlyCollection : ReadOnlyCollectionBase, ICollection, IEnumerable

Inheritance: objectReadOnlyCollectionBaseRadItemReadOnlyCollection

Implements: ICollectionIEnumerable

Inherited Members ReadOnlyCollectionBase.InnerListReadOnlyCollectionBase.Count

Constructors

RadItemReadOnlyCollection(RadItemOwnerCollection)

Initializes a new instance of RadItemCollection based on another RadItemCollection.

Declaration

cs-api-definition
public RadItemReadOnlyCollection(RadItemOwnerCollection value)

Parameters

value

RadItemOwnerCollection

A RadItemCollection from which the contents are copied

RadItemReadOnlyCollection(RadItem[])

Initializes a new instance of RadItemCollection containing any array of RadElement objects.

Declaration

cs-api-definition
public RadItemReadOnlyCollection(RadItem[] value)

Parameters

value

RadItem[]

A array of RadElement objects with which to intialize the collection

Properties

this[int]

Represents the entry at the specified index of the RadElement.

Declaration

cs-api-definition
public RadItem this[int index] { get; }

Parameters

index

int

The zero-based index of the entry to locate in the collection.

Property Value

RadItem

The entry at the specified index of the collection.

Exceptions

ArgumentOutOfRangeException

index is outside the valid range of indexes for the collection.

Methods

Contains(RadItem)

Gets a value indicating whether the RadItemCollection contains the specified RadElement.

Declaration

cs-api-definition
public bool Contains(RadItem value)

Parameters

value

RadItem

The RadElement to locate.

Returns

bool

true if the RadElement is contained in the collection; otherwise, false.

CopyTo(RadItem[], int)

Copies the RadItemCollection values to a one-dimensional Array instance at the specified index.

Declaration

cs-api-definition
public void CopyTo(RadItem[] array, int index)

Parameters

array

RadItem[]

The one-dimensional Array that is the destination of the values copied from RadItemCollection .

index

int

The index in array where copying begins.

Exceptions

ArgumentException

array is multidimensional.

-or-

The number of elements in the RadItemCollection is greater than the available space between index and the end of array.

ArgumentNullException

array is null.

ArgumentOutOfRangeException

index is less than array's lowbound.

GetEnumerator()

Declaration

cs-api-definition
public RadItemReadOnlyCollection.RadItemReadOnlyEnumerator GetEnumerator()

Returns

RadItemReadOnlyCollection.RadItemReadOnlyEnumerator

IndexOf(RadItem)

Returns the index of a RadElement in the RadItemCollection .

Declaration

cs-api-definition
public int IndexOf(RadItem value)

Parameters

value

RadItem

The RadElement to locate.

Returns

int

The index of the RadElement of value in the RadItemCollection, if found; otherwise, -1.

OnItemsChanged(RadItemCollection, RadItem, ItemsChangeOperation)

Declaration

cs-api-definition
protected virtual void OnItemsChanged(RadItemCollection changed, RadItem target, ItemsChangeOperation operation)

Parameters

changed

RadItemCollection

target

RadItem

operation

ItemsChangeOperation

Sort()

Sorts the elements in the entire RadElementCollection using the IComparable implementation of each element.

Declaration

cs-api-definition
public void Sort()

Sort(IComparer)

Sorts the elements in the entire RadElementCollection using the specified comparer.

Declaration

cs-api-definition
public void Sort(IComparer comparer)

Parameters

comparer

IComparer

The IComparer implementation to use when comparing elements.

Sort(int, int, IComparer)

Sorts the elements in a range of elements in RadElementCollection using the specified comparer.

Declaration

cs-api-definition
public void Sort(int index, int count, IComparer comparer)

Parameters

index

int

The zero-based starting index of the range to sort.

count

int

The length of the range to sort.

comparer

IComparer

The IComparer implementation to use when comparing elements.

ToArray()

Retrieves an array of the items in the collection.

Declaration

cs-api-definition
public RadItem[] ToArray()

Returns

RadItem[]

Events

ItemsChanged

Declaration

cs-api-definition
public event ItemChangedDelegate ItemsChanged

Event Value

ItemChangedDelegate