|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ehcache.clustered.client.config.TimeoutDuration
public final class TimeoutDuration
Describes a timeout value for a clustered operation. Instances of this class
are subject to the operation of the Java java.util.concurrent.TimeUnit
class.
Field Summary | |
---|---|
static TimeoutDuration |
NONE
Constant indicating no timeout. |
Method Summary | |
---|---|
long |
convert(java.util.concurrent.TimeUnit toUnit)
Converts this TimeDuration to the specified time unit. |
boolean |
equals(java.lang.Object other)
|
int |
hashCode()
|
static TimeoutDuration |
of(long amount,
java.util.concurrent.TimeUnit unit)
Gets a TimeoutDuration of the indicated duration. |
void |
timedWait(java.lang.Object obj)
Performs a timed wait on the object provided. |
long |
toMillis()
Converts this TimeoutDuration to milliseconds. |
long |
toNanos()
Converts this TimeoutDuration to nanoseconds. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final TimeoutDuration NONE
Method Detail |
---|
public static TimeoutDuration of(long amount, java.util.concurrent.TimeUnit unit)
TimeoutDuration
of the indicated duration.
amount
- the non-negative timeout durationunit
- the non-null
units for amount
TimeoutDuration
instance for the specified duration
java.lang.NullPointerException
- if unit
is null
java.lang.IllegalArgumentException
- if amount
is negativepublic long toNanos()
TimeoutDuration
to nanoseconds. Values are converted
according to the rules for java.util.concurrent.TimeUnit
.
TimeDuration
public long toMillis()
TimeoutDuration
to milliseconds. Values are converted
according to the rules for java.util.concurrent.TimeUnit
.
TimeDuration
public long convert(java.util.concurrent.TimeUnit toUnit)
TimeDuration
to the specified time unit. Values are
converted according to the rules for java.util.concurrent.TimeUnit
.
toUnit
- the TimeUnit
to which this TimeDuration
value is converted
toUnit
unitsTimeUnit.convert(long, TimeUnit)
public void timedWait(java.lang.Object obj) throws java.lang.InterruptedException
obj
- the Object
on which to wait
java.lang.InterruptedException
- if the wait is interruptedTimeUnit.timedWait(Object, long)
public boolean equals(java.lang.Object other)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |