New to Telerik UI for WPFStart a free 30-day trial

A partially observable wrapper for the a hash set that contains the checked items of the RadTreeView.

Definition

Namespace:Telerik.Windows.Controls.TreeView

Assembly:Telerik.Windows.Controls.Navigation.dll

Syntax:

C#
public class CheckedItemsCollection : ICollection<object>, IEnumerable<object>, ICollection, IEnumerable, INotifyPropertyChanged, INotifyCollectionChanged

Inheritance: objectCheckedItemsCollection

Implements: ICollectionICollection<object>IEnumerableIEnumerable<object>INotifyCollectionChangedINotifyPropertyChanged...

Properties

Gets the number of elements contained in the ICollection.

C#
public int Count { get; }

Implements: ICollection<object>.CountICollection.Count

Gets a value indicating whether the ICollection<T> is read-only.

C#
public bool IsReadOnly { get; }

Implements: ICollection<object>.IsReadOnly

Gets a value indicating whether access to the ICollection is synchronized (thread safe).

C#
public bool IsSynchronized { get; }

Implements: ICollection.IsSynchronized

Gets an object that can be used to synchronize access to the ICollection.

C#
public object SyncRoot { get; }

Implements: ICollection.SyncRoot

Methods

Adding items to the CheckedItemsCollection is currently not supported, calling this method will throw an exception.

C#
public void Add(object item)
Parameters:itemobject

No item will be added to the collection, regardless of the parameter.

Implements: ICollection<object>.Add(object)

The collection is Readonly, calling this method will result in an exception.

C#
public void Clear()

Implements: ICollection<object>.Clear()

Determines whether the ICollection<T> contains a specific value.

C#
public bool Contains(object item)
Parameters:itemobject

The object to locate in the ICollection<T>.

Returns:

bool

True if item is found in the ICollection<T>; otherwise, false.

Implements: ICollection<object>.Contains(object)

Copies the elements of the ICollection to an Array, starting at a particular Array index.

C#
public void CopyTo(Array array, int index)
Parameters:arrayArray

The one-dimensional Array that is the destination of the elements copied from ICollection. The Array must have zero-based indexing.

indexint

The zero-based index in array at which copying begins.

Exceptions:

ArgumentNullException

array is null.

ArgumentOutOfRangeException

index is less than zero.

ArgumentException

array is multidimensional. -or- index is equal to or greater than the length of array. -or- The number of elements in the source ICollection is greater than the available space from index to the end of the destination array.

ArgumentException

The type of the source ICollection cannot be cast automatically to the type of the destination array.

Implements: ICollection.CopyTo(Array, int)

Copies the elements of the ICollection<T> to an Array, starting at a particular Array index.

C#
public void CopyTo(object[] array, int arrayIndex)
Parameters:arrayobject[]

The one-dimensional Array that is the destination of the elements copied from ICollection<T>. The Array must have zero-based indexing.

arrayIndexint

The zero-based index in array at which copying begins.

Exceptions:

ArgumentNullException

array is null.

ArgumentOutOfRangeException

arrayIndex is less than 0.

ArgumentException

array is multidimensional. -or- arrayIndex is equal to or greater than the length of array. -or- The number of elements in the source ICollection<T> is greater than the available space from arrayIndex to the end of the destination array.

Implements: ICollection<object>.CopyTo(object[], int)

Returns the items from the collection that have a ToggleState.On and excludes items with ToggleState.Indeterminate.

C#
public IEnumerator<object> GetCheckedItemsOnly()
Returns:

IEnumerator<object>

An enumerator that returns only the checked items which are not in indeterminate state.

Returns an enumerator that iterates through a collection.

C#
public IEnumerator GetEnumerator()
Returns:

IEnumerator

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

Implements: IEnumerable.GetEnumerator()

The CheckedItems collection is read-only and cannot be modified.

C#
public bool Remove(object item)
Parameters:itemobject

No item will be remove, the collection is read-only.

Returns:

bool

Always returns false.

Implements: ICollection<object>.Remove(object)

Events

Raised when the CheckedItems change. Currently it is only raised with 'Reset' since the set of items in unordered.

C#
public event NotifyCollectionChangedEventHandler CollectionChanged

Implements: INotifyCollectionChanged.CollectionChanged

Raised when a property changes on the object.

C#
public event PropertyChangedEventHandler PropertyChanged

Implements: INotifyPropertyChanged.PropertyChanged