XRValueCollectionT<IFace,ItemType> (Compact 7)
3/12/2014
This C++ template class is an intermediate base class for collections of data source objects of type ItemType.
Syntax
template<typename IFace, typename ItemType>
class XRValueCollectionT : public _XRValueCollectionBaseT<IFace, ItemType, _ItemComparer, _ItemConverter, _ItemLifeManager>
Inheritance Hierarchy
_XRValueCollectionBaseT<IFace,ItemType,ItemComparer,ItemConverter,ItemLifeManager>
XRValueCollectionT<IFace,ItemType>
Members
Template Parameters
Value | Description |
---|---|
IFace |
A Silverlight for Windows Embedded interface that the class supports. |
ItemType |
The class type for items in the collection. |
Methods
Methods | Description |
---|---|
Adds an item of type ItemType to the collection. |
|
Determines whether an item of type ItemType is in the collection. |
|
Obtains the item at the specified index within the collection. |
|
Provides a type-safe version of the XRValueCollectionT.GetItem(int,ItemType *) method that obtains the item at the specified index of the collection. |
|
Determines the index of the specified item in the collection. |
|
Inserts an item into the collection at the specified index in the collection. |
|
Removes the specified item of type ItemType from the collection. |
|
Updates the data source object at the specified index within the collection by replacing it with a new data source object. |
Thread Safety
Members of this class are not thread safe when you add, remove, update, or clear the objects in the collection. When you are updating objects with new data from the data provider, implement single-threading and block other operations until the update is finished.
Remarks
To specify the class type for items stored in the collection, set the ItemType template parameter.
Do not instantiate this class directly. Instead, instantiate a derived class that overrides the inherited Impl methods, such as XRObservableCollection<ItemType> or XRValueCollection<ItemType>.
XRValueCollection<ItemType> and XRObservableCollection<ItemType> are derived classes that you can use as the data context for an IXRItemsControl that displays dynamic data.
Requirements
Header |
XRCollection.h |