org.apache.tools.ant.taskdefsClass WaitFor.Unit
- java.lang.Object
- org.apache.tools.ant.types.EnumeratedAttribute
- org.apache.tools.ant.taskdefs.WaitFor.Unit
- Enclosing class:
- WaitFor
public static class WaitFor.Unit extends EnumeratedAttributeThe enumeration of units: millisecond, second, minute, hour, day, week
- To do:
- we use timestamps in many places, why not factor this out
Field Summary
Fields Modifier and Type Field and Description static java.lang.String
DAY
day stringstatic java.lang.String
HOUR
hour stringstatic java.lang.String
MILLISECOND
millisecond stringstatic java.lang.String
MINUTE
minute stringstatic java.lang.String
SECOND
second stringstatic java.lang.String
WEEK
week string
Fields inherited from class org.apache.tools.ant.types.EnumeratedAttribute
value
Constructor Summary
Constructors Constructor and Description Unit()
Constructor the Unit enumerated type.
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description long
getMultiplier()
Convert the value to a multipler (millisecond to unit).java.lang.String[]
getValues()
This is the only method a subclass needs to implement.
Methods inherited from class org.apache.tools.ant.types.EnumeratedAttribute
containsValue, getIndex, getInstance, getValue, indexOfValue, setValue, toString
Field Detail
MILLISECOND
public static final java.lang.String MILLISECONDmillisecond string
- See Also:
- Constant Field Values
SECOND
public static final java.lang.String SECONDsecond string
- See Also:
- Constant Field Values
MINUTE
public static final java.lang.String MINUTEminute string
- See Also:
- Constant Field Values
HOUR
public static final java.lang.String HOURhour string
- See Also:
- Constant Field Values
DAY
public static final java.lang.String DAYday string
- See Also:
- Constant Field Values
WEEK
public static final java.lang.String WEEKweek string
- See Also:
- Constant Field Values
Method Detail
getMultiplier
public long getMultiplier()Convert the value to a multipler (millisecond to unit).
- Returns:
- a multipler (a long value)
getValues
public java.lang.String[] getValues()Description copied from class:EnumeratedAttribute
This is the only method a subclass needs to implement.
- Specified by:
getValues
in classEnumeratedAttribute
- Returns:
- an array holding all possible values of the enumeration. The order of elements must be fixed so that indexOfValue(String) always return the same index for the same value.
- See Also:
{@inheritDoc}