Class IntervalTimer
java.lang.Object
com.swiftmq.impl.streams.comp.timer.IntervalTimer
- All Implemented Interfaces:
Timer
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes this Timer.voidcollect(long interval) Internal usedays(int n) Adds n days to the interval.voidInternal use.com.swiftmq.swiftlet.timer.event.TimerListenerInternal use.hours(int n) Adds n hours to the interval.milliseconds(long n) Adds n days to the milliseconds.minutes(int n) Adds n minutes to the interval.name()Returns the name of the Timer.onTimer(TimerCallback callback) Sets the onTimer callback.voidReconfigures this Timer and applies new settingsreset()Resets the value of a Timerseconds(int n) Adds n seconds to the interval.voidsetTimerListener(com.swiftmq.swiftlet.timer.event.TimerListener listener) Internal use.voidstart()Starts this Timer.toString()
-
Method Details
-
days
Adds n days to the interval.- Parameters:
n- days- Returns:
- IntervalTimer
-
hours
Adds n hours to the interval.- Parameters:
n- hours- Returns:
- IntervalTimer
-
minutes
Adds n minutes to the interval.- Parameters:
n- minutes- Returns:
- IntervalTimer
-
seconds
Adds n seconds to the interval.- Parameters:
n- seconds- Returns:
- IntervalTimer
-
milliseconds
Adds n days to the milliseconds.- Parameters:
n- milliseconds- Returns:
- IntervalTimer
-
executeCallback
Description copied from interface:TimerInternal use.- Specified by:
executeCallbackin interfaceTimer- Throws:
Exception
-
setTimerListener
public void setTimerListener(com.swiftmq.swiftlet.timer.event.TimerListener listener) Description copied from interface:TimerInternal use.- Specified by:
setTimerListenerin interfaceTimer
-
getTimerListener
public com.swiftmq.swiftlet.timer.event.TimerListener getTimerListener()Description copied from interface:TimerInternal use.- Specified by:
getTimerListenerin interfaceTimer
-
name
-
onTimer
Description copied from interface:TimerSets the onTimer callback. -
collect
-
start
-
reset
-
reconfigure
Description copied from interface:TimerReconfigures this Timer and applies new settings- Specified by:
reconfigurein interfaceTimer- Throws:
Exception
-
close
-
toString
-