The values() method returns an array that contains a list of enumeration constants. The general form of the values method is as follows:
The valueOf() method returns the enumeration constant that contains the value of the corresponding string. The general form of the values method is as follows:
All the declared enumerations contain the two methods automatically. In both general forms, enum-type will be the return type of the enumeration.
Pass SUN scja - SCJA Download free practice test for CX310-019 SCJA exam.