In designing a class for customer for example would it make sense to use an Enum for CustomerType?
+3
A:
That depends on other constraints. You haven't told us enough about your model. For example, if different types of customers have different types of information associated with them, a class hierarchy will be better suited that an a mere enum.
In other cases, an enum will be fine or might even be preferred (simpler, reduced overhead …).
Konrad Rudolph
2008-11-16 17:54:37