Interface Timer
- All Known Implementing Classes:
AtTimer,IntervalTimer,NextTimer
public interface Timer
Base interface for Timers.
- Author:
- IIT Software GmbH, Muenster/Germany, (c) 2016, All Rights Reserved
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes this Timer.voidcollect(long interval) Internal usevoidInternal use.TimerListenerInternal use.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 TimervoidsetTimerListener(TimerListener listener) Internal use.voidstart()Starts this Timer.
-
Method Details
-
setTimerListener
void setTimerListener(TimerListener listener) Internal use. -
getTimerListener
TimerListener getTimerListener()Internal use. -
name
String name()Returns the name of the Timer.- Returns:
- Name
-
onTimer
Sets the onTimer callback.- Parameters:
callback- callback- Returns:
- Timer
-
executeCallback
Internal use.- Throws:
Exception
-
collect
void collect(long interval) Internal use -
start
Starts this Timer. This method is called automatically if a Timer is created outside a callback. If it is created inside, it must be called explicitly.- Throws:
Exception
-
reset
Timer reset()Resets the value of a Timer -
reconfigure
Reconfigures this Timer and applies new settings- Throws:
Exception
-
close
void close()Closes this Timer.
-