IIterable<T> IIterable<T> IIterable<T> IIterable<T> Interface

Definition

Exposes an iterator that supports simple iteration over a collection of a specified type.

.NET This interface appears as System.Collections.Generic.IEnumerable. In any case where a Windows Runtime type has implemented IIterable;, .NET code can use the APIs of IEnumerable instead. C# code can use foreach, Visual Basic code can use For Each...Next. All the .NET extension methods that are based on IEnumerable and included in .NET for Windows Store app are accessible (including the System.Linq extensions, so long as you've included the namespace).

public : interface IIterable<T>public interface IIterable<T>Public Interface IIterable<T>// You can use this interface in JavaScript.
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.FoundationContract (introduced v1)

Remarks

When programming with .NET, this interface is hidden and developers should use the System.Collections.Generic.IEnumerable interface. Because of how the projections were done, the GetEnumerator method isn't always available as a direct callable method on the types that project IEnumerable as implemented, but enumerating the collection with the standard enumeration syntax (foreach) is still supported. The compiler does the type-casting for you and you won't need to cast to IEnumerable explicitly. If you do need to cast explicitly, for example if you want to call GetEnumerator from a class, cast to IEnumerable, using a constraint in the cast that matches the item type of the collection.

Methods

First() First() First() First()

Returns an iterator for the items in the collection.

public : IIterator<T> First()public IIterator<T> First()Public Function First() As IIterator( Of T )// You can use this method in JavaScript.
Returns

Remarks

When programming with .NET, this interface is hidden and developers should use the System.Collections.Generic.IEnumerable interface.

See Also