T
Tony Johansson
Hi!
In the code below I use the Enumerator that is called on class List<string>
Here is a link that show every member in the List<T> class
http://msdn.microsoft.com/en-us/library/d9hw1as6.aspx
If I carefully look through all these members I can't find a sight of any
Enumerator.
Can anybody explain that ??
If I google for List<T>.Enumerator this specific member is found but why is
not this listed when I
look at all the members in the List<T> class.
public static void Main()
{
List<string> stringList = new List<string>();
stringList.Add("opel");
stringList.Add("saab");
stringList.Add("volvo");
stringList.Add("fiat");
List<string>.Enumerator e = stringList.GetEnumerator();
while (e.MoveNext())
Console.WriteLine(e.Current);
}
//Tony
In the code below I use the Enumerator that is called on class List<string>
Here is a link that show every member in the List<T> class
http://msdn.microsoft.com/en-us/library/d9hw1as6.aspx
If I carefully look through all these members I can't find a sight of any
Enumerator.
Can anybody explain that ??
If I google for List<T>.Enumerator this specific member is found but why is
not this listed when I
look at all the members in the List<T> class.
public static void Main()
{
List<string> stringList = new List<string>();
stringList.Add("opel");
stringList.Add("saab");
stringList.Add("volvo");
stringList.Add("fiat");
List<string>.Enumerator e = stringList.GetEnumerator();
while (e.MoveNext())
Console.WriteLine(e.Current);
}
//Tony