Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

3
  • Does this answer your question? Approaches to checking multiple conditions? Commented Apr 5, 2020 at 20:23
  • 2
    If you cannot recollect and recite all potential values of an enum within a few seconds after the moment you define it (provided that you have properly thought about it up front), chances are you are messing up (you are using the wrong kind of abstraction). Use an interface and classes instead. enum constructs do not really serve "future extensibility" that well. Commented Apr 7, 2020 at 1:40
  • While I'm not sure I agree with your reasoning, I do agree that an interface and classes is ultimately more maintainable. Commented Apr 8, 2020 at 20:53