public static final class DurationSpec.LongSecondsBound extends DurationSpec
DurationSpec.IntMillisecondsBound, DurationSpec.IntMinutesBound, DurationSpec.IntSecondsBound, DurationSpec.LongMillisecondsBound, DurationSpec.LongNanosecondsBound, DurationSpec.LongSecondsBound
Constructor and Description |
---|
LongSecondsBound(long seconds)
Creates a
DurationSpec.LongSecondsBound of the specified amount in seconds. |
LongSecondsBound(long quantity,
java.util.concurrent.TimeUnit unit)
Creates a
DurationSpec.LongSecondsBound of the specified amount in the specified unit. |
LongSecondsBound(java.lang.String value)
Creates a
DurationSpec.LongSecondsBound of the specified amount. |
Modifier and Type | Method and Description |
---|---|
long |
toMilliseconds() |
long |
toSeconds() |
public LongSecondsBound(java.lang.String value)
DurationSpec.LongSecondsBound
of the specified amount.
The bound is [0, Long.MAX_VALUE) in seconds.value
- the durationpublic LongSecondsBound(long quantity, java.util.concurrent.TimeUnit unit)
DurationSpec.LongSecondsBound
of the specified amount in the specified unit.
The bound is [0, Long.MAX_VALUE) in seconds.quantity
- where quantity shouldn't be bigger than Long.MAX_VALUE - 1 in secondsunit
- in which the provided quantity ispublic LongSecondsBound(long seconds)
DurationSpec.LongSecondsBound
of the specified amount in seconds.
The bound is [0, Long.MAX_VALUE) in seconds.seconds
- where seconds shouldn't be bigger than Long.MAX_VALUE-1Copyright © 2009- The Apache Software Foundation