Serializable, Comparable<Clock.TimeFormat>public static enum Clock.TimeFormat extends Enum<Clock.TimeFormat>
| 枚举常量 | 说明 |
|---|---|
CLOCK_12 |
12-hour format.
|
CLOCK_24 |
24-hour format.
|
CLOCK_SYSTEM |
System time format.
|
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
protected int |
getValue() |
Obtains the value of the TimeFormat type.
|
static Clock.TimeFormat |
valueOf(String name) |
返回带有指定名称的该类型的枚举常量。
字符串必须与用于声明该类型的枚举常量的
标识符完全匹配。(不允许有多余
的空格字符。)
|
static Clock.TimeFormat[] |
values() |
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。该方法可用于迭代
常量, 如下所示:
for (Clock.TimeFormat c : Clock.TimeFormat.values()) System.out.println(c); |
public static final Clock.TimeFormat CLOCK_12
public static final Clock.TimeFormat CLOCK_24
public static final Clock.TimeFormat CLOCK_SYSTEM
public static Clock.TimeFormat[] values()
for (Clock.TimeFormat c : Clock.TimeFormat.values()) System.out.println(c);
public static Clock.TimeFormat valueOf(String name)
name - 要返回的枚举常量的名称。IllegalArgumentException - 如果该枚举类型没有带有指定名称的常量NullPointerException - 如果参数为空值protected int getValue()