Namely any enum
valueof()
(not the class Enum
) will not require try/catch for IllegalArgumentException
.
I had to look here, and at the Enum
class, to know about it.
As a bonus answer, I would like to know if there is some way to make the IDE require these try/catch blocks. Namely Eclipse IDE.
PS.: I am using Eclipse Luna 4.4.2, an upgrade suggestion is acceptable also.