public class CronThreadPoolExecutor extends ScheduledThreadPoolExecutor implements CronExecutorService
ThreadPoolExecutor.AbortPolicy, ThreadPoolExecutor.CallerRunsPolicy, ThreadPoolExecutor.DiscardOldestPolicy, ThreadPoolExecutor.DiscardPolicy
Constructor and Description |
---|
CronThreadPoolExecutor(int corePoolSize)
Constructs a new CronThreadPoolExecutor.
|
CronThreadPoolExecutor(int corePoolSize,
RejectedExecutionHandler handler)
Constructs a new CronThreadPoolExecutor.
|
CronThreadPoolExecutor(int corePoolSize,
ThreadFactory threadFactory)
Constructs a new CronThreadPoolExecutor.
|
CronThreadPoolExecutor(int corePoolSize,
ThreadFactory threadFactory,
RejectedExecutionHandler handler)
Constructs a new CronThreadPoolExecutor.
|
Modifier and Type | Method and Description |
---|---|
void |
schedule(Runnable task,
CronExpression expression)
Schedules the specified task to execute according to the specified cron expression.
|
decorateTask, decorateTask, execute, getContinueExistingPeriodicTasksAfterShutdownPolicy, getExecuteExistingDelayedTasksAfterShutdownPolicy, getQueue, getRemoveOnCancelPolicy, schedule, schedule, scheduleAtFixedRate, scheduleWithFixedDelay, setContinueExistingPeriodicTasksAfterShutdownPolicy, setExecuteExistingDelayedTasksAfterShutdownPolicy, setRemoveOnCancelPolicy, shutdown, shutdownNow, submit, submit, submit
afterExecute, allowCoreThreadTimeOut, allowsCoreThreadTimeOut, awaitTermination, beforeExecute, finalize, getActiveCount, getCompletedTaskCount, getCorePoolSize, getKeepAliveTime, getLargestPoolSize, getMaximumPoolSize, getPoolSize, getRejectedExecutionHandler, getTaskCount, getThreadFactory, isShutdown, isTerminated, isTerminating, prestartAllCoreThreads, prestartCoreThread, purge, remove, setCorePoolSize, setKeepAliveTime, setMaximumPoolSize, setRejectedExecutionHandler, setThreadFactory, terminated, toString
invokeAll, invokeAll, invokeAny, invokeAny, newTaskFor, newTaskFor
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
awaitTermination, invokeAll, invokeAll, invokeAny, invokeAny, isShutdown, isTerminated, shutdown, shutdownNow, submit, submit, submit
public CronThreadPoolExecutor(int corePoolSize)
corePoolSize
- public CronThreadPoolExecutor(int corePoolSize, ThreadFactory threadFactory)
corePoolSize
- public CronThreadPoolExecutor(int corePoolSize, RejectedExecutionHandler handler)
corePoolSize
- public CronThreadPoolExecutor(int corePoolSize, ThreadFactory threadFactory, RejectedExecutionHandler handler)
corePoolSize
- handler
- public void schedule(Runnable task, CronExpression expression)
schedule
in interface CronExecutorService
task
- the Runnable task to scheduleexpression
- a cron expressionCronExecutorService.schedule(java.lang.Runnable, net.sf.hajdbc.util.concurrent.cron.CronExpression)
Copyright © 2004–2014 Paul Ferraro. All rights reserved.