|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | |||||||||
java.lang.Objectjava.lang.Enum<DurationFormat>
org.mindswap.pellet.utils.DurationFormat
public enum DurationFormat
Title:
Description: A simple class to provide various formatting options for durations represented in milliseconds. The durations are displayed in terms of hours, minutes, seconds, and milliseconds.
Copyright: Copyright (c) 2009
Company: Clark & Parsia, LLC.
| Enum Constant Summary | |
|---|---|
FULL
Format duration in full format. |
|
LONG
Format duration in long format. |
|
MEDIUM
Format duration in medium format (no milliseconds). |
|
SHORT
Format duration in short format (no hours or milliseconds). |
|
| Method Summary | |
|---|---|
java.lang.String |
format(long durationInMilliseconds)
Format the given duration in milliseconds according to the style defined by this DurationFormat class. |
static DurationFormat |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static DurationFormat[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
| Methods inherited from class java.lang.Enum |
|---|
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Enum Constant Detail |
|---|
public static final DurationFormat FULL
public static final DurationFormat LONG
public static final DurationFormat MEDIUM
public static final DurationFormat SHORT
| Method Detail |
|---|
public static DurationFormat[] values()
for (DurationFormat c : DurationFormat.values()) System.out.println(c);
public static DurationFormat 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 name
java.lang.NullPointerException - if the argument is nullpublic java.lang.String format(long durationInMilliseconds)
durationInMilliseconds - duration represented in milliseconds
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | |||||||||