Showing posts with label IEnumerator and IEnumerable Interface. Show all posts
Showing posts with label IEnumerator and IEnumerable Interface. Show all posts

Sunday, 29 December 2013

IEnumerator and IEnumerable Interface

IEnumerator and IEnumerable Interface

In simple term collection in C# is a way to store objects. We use System.Collection namespace to work with collection.

IEnumerator and IEnumerable

In collection we are able to access the each element using Enumerator. There is an Interface IEnumerator which contains the following method and properties:-

namespace System.Collections
{
    public interface IEnumerator
    {