Package com.tenio.core.schedule.task
Class AbstractSystemTask
java.lang.Object
com.tenio.common.logger.AbstractLogger
com.tenio.common.logger.SystemLogger
com.tenio.core.schedule.task.AbstractSystemTask
- All Implemented Interfaces:
com.tenio.common.task.Task
- Direct Known Subclasses:
AutoCleanOrphanSessionTask,AutoDisconnectPlayerTask,AutoRemoveRoomTask,CcuReportTask,DeadlockScanTask,KcpUpdateTask,SystemMonitoringTask,TrafficCounterTask
public abstract class AbstractSystemTask
extends com.tenio.common.logger.SystemLogger
implements com.tenio.common.task.Task
The abstract task for system related schedule.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected EventManagerThe event manager.protected intThe initial delay time.protected intThe interval value. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractSystemTask(EventManager eventManager) Initialization. -
Method Summary
Methods inherited from class com.tenio.common.logger.SystemLogger
debug, debugEvent, isDebugEnabled, isTraceEnabled, trace, traceMethods inherited from class com.tenio.common.logger.AbstractLogger
buildgen, error, error, error, info, info, info, info, info, info, info, info, isErrorEnabled, isInfoEnabledMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.tenio.common.task.Task
run
-
Field Details
-
eventManager
The event manager. -
interval
protected int intervalThe interval value. -
initialDelay
protected int initialDelayThe initial delay time. The task should wait a little until the system becomes stable.
-
-
Constructor Details
-
AbstractSystemTask
Initialization.- Parameters:
eventManager- the event manager
-
-
Method Details
-
setInterval
public void setInterval(int interval) Set the interval.- Parameters:
interval- the value
-