using System.Collections.Generic;
public static void Main()
foreach (BiasCode biasCode in new BiasCode().Values())
public static void DisplayEnum(BiasCode biasCode)
Console.WriteLine(biasCode);
public static class EnumExtensions
public static List<T> Values<T>(this T theEnum)
where T : struct, IComparable, IFormattable, IConvertible
throw new InvalidOperationException(string.Format("Type {0} is not enum.", typeof(T).FullName));
return Enum.GetValues(theEnum.GetType()).Cast<T>().ToList();