About 9,450,000 results
Open links in new tab
  1. What is IEnumerable in .NET? - Stack Overflow

    Jun 10, 2010 · I think IEnumerable is poorly named. Mathematically, and in computing, an enumerable is anything that maps to a countable set. So outside of .net an IObservable may be enumerable. In …

  2. IEnumerable vs List - What to Use? How do they work?

    Sep 2, 2010 · IEnumerable describes behavior, while List is an implementation of that behavior. When you use IEnumerable, you give the compiler a chance to defer work until later, possibly optimizing …

  3. Can anyone explain IEnumerable and IEnumerator to me?

    IEnumerable is an interface defining a single method GetEnumerator() that returns an IEnumerator interface. This works for read-only access to a collection that implements that IEnumerable can be …

  4. What's the role of IEnumerable<T> and why should I use it?

    IEnumerable<T> is an interface that tells us that we can enumerate over a sequence of T instances. If you need to allow somebody to see and perform some action for each object in a collection, this is …

  5. What is the difference between IEnumerator and IEnumerable?

    IEnumerable is an interface that defines one method GetEnumerator which returns an IEnumerator interface, this in turn allows readonly access to a collection. A collection that implements …

  6. .net - Initializing IEnumerable<string> In C# - Stack Overflow

    IEnumerable is an interface, instead of looking for how to create an interface instance, create an implementation that matches the interface: create a list or an array.

  7. c# - How do I implement IEnumerable<T> - Stack Overflow

    Jul 2, 2012 · I know how to implement the non generic IEnumerable, like this: using System; using System.Collections; namespace ConsoleApplication33 { class Program { static void Main(string[] ...

  8. What's the difference between IEnumerable and Array, IList and List?

    Apr 19, 2009 · IEnumerable is a general-purpose interface that is used by many classes, such as Array, List and String in order to let someone iterate over a collection. Basically, it's what drives the foreach …

  9. How can I add an item to a IEnumerable<T> collection?

    IEnumerable<T> is meant for querying collections only. It is the backbone for the LINQ framework. It is always an abstraction of some other collection such as Collection<T>, List<T>, or Array. The …

  10. Why use ICollection and not IEnumerable or List<T> on many …

    IEnumerable has one property: Current, which returns the current element. ICollection implements IEnumerable and adds few additional properties the most use of which is Count. The generic version …