Enum Constant and Description |
---|
CLASSICAL |
HIPHOP |
JAZZ |
POP |
RAP |
ROCK |
Modifier and Type | Method and Description |
---|---|
static Genre |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static Genre[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Genre JAZZ
public static final Genre CLASSICAL
public static final Genre HIPHOP
public static final Genre ROCK
public static final Genre POP
public static final Genre RAP
public static Genre[] values()
for (Genre c : Genre.values()) System.out.println(c);
public static Genre valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null