Class DelayedEvent
java.lang.Object
cl.netswitch.lib.server.DelayedEvent
- All Implemented Interfaces:
Comparable<Delayed>, Delayed
-
Method Summary
Modifier and TypeMethodDescriptionfinal intCompares this DelayedEvent with the specified object for order.abstract voiddispatch()Dispatched this DelayedEvent to the target listener.final booleanIndicates whether some other object is "equal to" this DelayedEvent.final longReturns the remaining delay in the given time unit.final inthashCode()Returns a hash code value of this DelayedEvent.
-
Method Details
-
getDelay
Returns the remaining delay in the given time unit.- Specified by:
getDelayin interfaceDelayed- Parameters:
unit- the required time unit of the output- Returns:
- the remaining delay in the given time unit.
- Throws:
NullPointerException- ifunitisnull.
-
hashCode
-
equals
-
compareTo
Compares this DelayedEvent with the specified object for order.- Specified by:
compareToin interfaceComparable<Delayed>- Parameters:
other- the object to compare to this DelayedEvent.- Returns:
- a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
- Throws:
NullPointerException- ifotherisnull.
-
dispatch
-