Package org.jboss.util.timeout
Class TimeoutPriorityQueueImpl.TimeoutExtImpl
- java.lang.Object
-
- org.jboss.util.timeout.TimeoutPriorityQueueImpl.TimeoutExtImpl
-
- All Implemented Interfaces:
Timeout
,TimeoutExt
- Enclosing class:
- TimeoutPriorityQueueImpl
private class TimeoutPriorityQueueImpl.TimeoutExtImpl extends java.lang.Object implements TimeoutExt
Our private Timeout implementation.
-
-
Constructor Summary
Constructors Modifier Constructor Description private
TimeoutExtImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
cancel()
Cancel this timeout.void
done()
Mark the work as donelong
getTime()
TimeoutTarget
getTimeoutTarget()
Get the target of this timeout
-
-
-
Field Detail
-
DONE
static final int DONE
Done- See Also:
- Constant Field Values
-
TIMEOUT
static final int TIMEOUT
In timeout- See Also:
- Constant Field Values
-
index
int index
Index in the queue
-
time
long time
Time of the timeout
-
target
TimeoutTarget target
The timeout target
-
-
Method Detail
-
getTime
public long getTime()
- Specified by:
getTime
in interfaceTimeoutExt
- Returns:
- the time of this timeout
-
getTimeoutTarget
public TimeoutTarget getTimeoutTarget()
Description copied from interface:TimeoutExt
Get the target of this timeout- Specified by:
getTimeoutTarget
in interfaceTimeoutExt
- Returns:
- the target
-
done
public void done()
Description copied from interface:TimeoutExt
Mark the work as done- Specified by:
done
in interfaceTimeoutExt
-
cancel
public boolean cancel()
Description copied from interface:Timeout
Cancel this timeout. It is guaranteed that on return from this method this timer is no longer active. This means that either it has been cancelled and the timeout will not happen, or (in case of late cancel) the timeout has happened and the timeout callback function has returned. On return from this method this instance should no longer be used. The reason for this is that an implementation may reuse cancelled timeouts, and at return the instance may already be in use for another timeout.
-
-