Class Limit.TimeUnit

java.lang.Object
org.apache.tools.ant.types.EnumeratedAttribute
net.sf.antcontrib.process.Limit.TimeUnit
Enclosing class:
Limit

public static class Limit.TimeUnit extends org.apache.tools.ant.types.EnumeratedAttribute
The enumeration of units: millisecond, second, minute, hour, day, week Todo: we use timestamps in many places, why not factor this out
  • Field Details

  • Constructor Details

    • TimeUnit

      public TimeUnit()
  • Method Details

    • setValueProgrammatically

      protected void setValueProgrammatically(String value)
      set the inner value programmatically.
      Parameters:
      value - to set
    • getMultiplier

      public long getMultiplier()
    • getValues

      public String[] getValues()
      Specified by:
      getValues in class org.apache.tools.ant.types.EnumeratedAttribute
    • toMillis

      public long toMillis(long numberOfUnits)
      convert the time in the current unit, to millis
      Parameters:
      numberOfUnits - long expressed in the current objects units
      Returns:
      long representing the value in millis