Archive for June 29th, 2009
Coding Tip #42: turning enums into classes
In Coding Tip #27 I explained how I rarely like to use booleans to represent states, and prefer to use an enum. Now that I have all nice little enums everywhere, another pattern that I see emerge is that I want more from my enum than just a value: perhaps other values associated with it, [...]
Posted: June 29th, 2009 under Design.
Comments: 5