i have a doubt about a best practice…
I have a bunch of enumerables inside my project and i dont want that they be separated, so my idea is to have one only class (or struct) with all the enumerables inside.. is that a good practice? If that is a good practice.. what is better? put all the enums inside a class or inside a struct?
Something like this:
public class (or struct) Enumerables{
public enum Enum1{a, b, c}
public enum Enum2{d, e, f}
}
I hope you can help me with this.
Thanks!
enums are Enumerations, not Enumerables.There’s also no need to isolate them in their own class. Just leave them as needed (they really act as a type of their own anyway). If they’re logically related, you can group them into their own namespace.