|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.camel.support.ServiceSupport
org.apache.camel.impl.DefaultScheduledPollConsumerScheduler
public class DefaultScheduledPollConsumerScheduler
| Field Summary |
|---|
| Fields inherited from class org.apache.camel.support.ServiceSupport |
|---|
shutdown, shuttingdown, started, starting, stopped, stopping, suspended, suspending |
| Constructor Summary | |
|---|---|
DefaultScheduledPollConsumerScheduler()
|
|
| Method Summary | |
|---|---|
protected void |
doShutdown()
Implementations override this method to perform customized shutdown. |
protected void |
doStart()
Implementations override this method to support customized start/stop. |
protected void |
doStop()
Implementations override this method to support customized start/stop. |
CamelContext |
getCamelContext()
Get the CamelContext |
long |
getDelay()
|
long |
getInitialDelay()
|
ScheduledExecutorService |
getScheduledExecutorService()
|
TimeUnit |
getTimeUnit()
|
boolean |
isSchedulerStarted()
Whether the scheduler has been started. |
boolean |
isUseFixedDelay()
|
void |
onInit(Consumer consumer)
Initializes this ScheduledPollConsumerScheduler with the associated Consumer. |
void |
scheduleTask(Runnable task)
Schedules the task to run. |
void |
setCamelContext(CamelContext camelContext)
Injects the CamelContext |
void |
setDelay(long delay)
|
void |
setInitialDelay(long initialDelay)
|
void |
setScheduledExecutorService(ScheduledExecutorService scheduledExecutorService)
|
void |
setTimeUnit(TimeUnit timeUnit)
|
void |
setUseFixedDelay(boolean useFixedDelay)
|
void |
startScheduler()
Starts the scheduler. |
void |
unscheduleTask()
Attempts to unschedules the last task which was scheduled. |
| Methods inherited from class org.apache.camel.support.ServiceSupport |
|---|
doResume, doSuspend, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, resume, shutdown, start, stop, suspend |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.camel.ShutdownableService |
|---|
shutdown |
| Methods inherited from interface org.apache.camel.Service |
|---|
start, stop |
| Constructor Detail |
|---|
public DefaultScheduledPollConsumerScheduler()
| Method Detail |
|---|
public CamelContext getCamelContext()
CamelContextAwareCamelContext
getCamelContext in interface CamelContextAwarepublic void setCamelContext(CamelContext camelContext)
CamelContextAwareCamelContext
setCamelContext in interface CamelContextAwarecamelContext - the Camel contextpublic long getInitialDelay()
public void setInitialDelay(long initialDelay)
public long getDelay()
public void setDelay(long delay)
public TimeUnit getTimeUnit()
public void setTimeUnit(TimeUnit timeUnit)
public boolean isUseFixedDelay()
public void setUseFixedDelay(boolean useFixedDelay)
public ScheduledExecutorService getScheduledExecutorService()
public void setScheduledExecutorService(ScheduledExecutorService scheduledExecutorService)
public void onInit(Consumer consumer)
ScheduledPollConsumerSchedulerScheduledPollConsumerScheduler with the associated Consumer.
onInit in interface ScheduledPollConsumerSchedulerconsumer - the consumer.public void scheduleTask(Runnable task)
ScheduledPollConsumerScheduler
scheduleTask in interface ScheduledPollConsumerSchedulertask - the task to run.public void unscheduleTask()
ScheduledPollConsumerScheduler
unscheduleTask in interface ScheduledPollConsumerSchedulerpublic void startScheduler()
ScheduledPollConsumerScheduler
startScheduler in interface ScheduledPollConsumerSchedulerpublic boolean isSchedulerStarted()
ScheduledPollConsumerScheduler
isSchedulerStarted in interface ScheduledPollConsumerScheduler
protected void doStart()
throws Exception
ServiceSupportServiceSupport.doStop() for more details.
doStart in class ServiceSupportExceptionServiceSupport.doStop()
protected void doStop()
throws Exception
ServiceSupportServiceSupport.doStop() method when
the service is being stopped. This method will also be invoked
if the service is still in uninitialized state (eg has not
been started). The method is always called to allow the service
to do custom logic when the service is being stopped, such as when
CamelContext is shutting down.
doStop in class ServiceSupportExceptionServiceSupport.doStart()
protected void doShutdown()
throws Exception
ServiceSupport
doShutdown in class ServiceSupportException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||