How to iterate over all the instances of a enum? code example
Example 1: iterate through an enum java
for (enumerator s : enumerator.values()) {
// do abc
}
Example 2: loop over all values in enum
var values = Enum.GetValues(typeof(Foos)).Cast<Foos>();