Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

IIterator<T> interface

Supports simple iteration over a collection.

Syntax


generic<typename T>
public interface class IIterator

Type parameters

T

The type of objects to iterate.

Members

The IIterator interface has these types of members:

Methods

The IIterator interface has these methods. It also inherits methods from the Object class.

MethodDescription
GetMany Retrieves all items in the collection.
MoveNext Advances the iterator to the next item in the collection.

 

Properties

The IIterator interface has these properties.

PropertyAccess typeDescription

Current

Read-onlyGets the current item in the collection.

HasCurrent

Read-onlyGets a value that indicates whether the iterator refers to a current item or is at the end of the collection.

 

Remarks

The IIterator<T> interface isn't explicitly hidden by the language projection for .NET, but the IIterable<T> interface is hidden. For most .NET scenarios that specifically require an API for the iterator object, you'll probably use IEnumerator<T> (perhaps with a specific type constraint) as obtained from calling IEnumerable<T>.GetEnumerator.

Requirements (Windows 10 device family)

Device family

Universal

API contract

Windows.Foundation.FoundationContract, introduced version 1.0

Namespace

Windows.Foundation.Collections
Windows::Foundation::Collections [C++]

Metadata

Windows.Foundation.FoundationContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8

Namespace

Windows.Foundation.Collections
Windows::Foundation::Collections [C++]

Metadata

Windows.winmd

Attributes

[Version(0x06020000)]

See also

IIterable<T>

 

 

Show:
© 2015 Microsoft