enum keyword in java
- 17th Aug 2017
- 0
- 3512
- advantage of using enum enum keyword in java with an example how to use enum keyword in java with an example when to use enum in java why do we need enum in java
The ” enum ” keyword is used to define a fixed set of constants. enum keyword is introduced in Java 5. It can be used for set of status in the application, set of some constant names in the project etc. The general syntax for an enum type is as follows: enum <enum_name> { […]