Working with an Enumeration Type

Use

An enumeration type allows you to define an abstract type that holds a list of values of the same primitive Java type that are logically related in a given context. An enumeration type is said to have a base type. Here the base type refers to the type of data that this enumeration type can hold.

This section describes the tasks you perform with an enumeration type.