Simplified getting enum array in the RandomEnumGenerator