Compartilhar via


IXRValueCollection (Compact 2013)

3/28/2014

This class represents the base class for an enumerable collection of XRValue objects.

Syntax

class IXRValueCollection : public IXREnumerable

Inheritance Hierarchy

IXREnumerable

    IXRValueCollection

Methods

Method

Description

IXRValueCollection::Add

Adds an item to the end of this collection and retrieves the index of where it was added.

IXRValueCollection::Clear

Removes all items from this collection.

IXRValueCollection::Contains

Determines whether an item is in this collection.

IXRValueCollection::GetCount

Retrieves the number of items in this collection.

IXRValueCollection::GetIsReadOnly

Determines whether this collection can be modified.

IXRValueCollection::Remove

Removes the last occurrence of a specific item from this collection.

Thread Safety

Members of this class are thread-safe if you previously called IXRApplication::CreateHostFromXaml and supplied it with an XRWindowCreateParams structure that has AllowsMultipleThreadAccess set to true.

Remarks

This class is used internally to provide enumeration capabilities to collections of dependency properties and attached properties that are passed through methods in .

IXRValueCollection is an entry in the interface map for _XRValueCollectionBaseT<IFace,ItemType,ItemComparer,ItemConverter,ItemLifeManager>. Therefore, you can use IUnknown::QueryInterface to request an IXRValueCollection interface pointer to an instance of a collection object that inherits from _XRValueCollectionBaseT<IFace,ItemType,ItemComparer,ItemConverter,ItemLifeManager>.

If you create a class instance, use an IXRValueCollectionPtr smart pointer instead of a raw interface pointer. For more information about smart pointer aliases, see XRPtr<Interface>.

.NET Framework Equivalent

System.Collections.Generic.ICollection<T>

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

Classes for Populating UI Elements with Data
XRCollectionChangedCustomEventArgs