Trying to create an uebersimple class that implements get enumerator, but failing madly due to lack of simple / non-functioning examples out there. All I want to do is create a
You can simply return the enumerator returned by List.GetEnumerator:
public class AlbumList : IEnumerable { // ... public IEnumerator GetEnumerator() { return this.albums.GetEnumerator(); } IEnumerator IEnumerable.GetEnumerator() { return GetEnumerator(); } }