Helping ordinary people create extraordinary websites!

Getting Started with Enumerated Types

By Brett McLaughlin
2005-04-22

Going Further
Enums can also be used in conjunction with sets, and much like the new EnumMap construct, Tiger supplies a new Set implementation EnumSet that allows you to work with bitwise operators. Additionally, you can add methods to your enums, use them to implement interfaces, and define what are called value-specific class bodies, where specific code is attached to a particular value of an enum. These features are beyond the scope of this article, but they're well documented elsewhere (see Resources).




Tutorial pages:

First published by IBM developerWorks


 2 Votes

You might also want to check these out:


Leave a Comment on "Getting Started with Enumerated Types"
You must be logged in to post a comment.

Link to This Tutorial Page!


GET OUR NEWSLETTERS