public class SimpleMainShutdownStrategy extends Object implements MainShutdownStrategy
MainShutdownStrategy.ShutdownEventListener| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
SimpleMainShutdownStrategy() |
| Modifier and Type | Method and Description |
|---|---|
void |
addShutdownListener(MainShutdownStrategy.ShutdownEventListener listener) |
void |
await()
Wait for main to complete.
|
void |
await(long timeout,
TimeUnit unit)
Wait for main to complete.
|
boolean |
isRunAllowed() |
boolean |
shutdown() |
public boolean isRunAllowed()
isRunAllowed in interface MainShutdownStrategypublic void addShutdownListener(MainShutdownStrategy.ShutdownEventListener listener)
addShutdownListener in interface MainShutdownStrategypublic boolean shutdown()
shutdown in interface MainShutdownStrategypublic void await()
throws InterruptedException
MainShutdownStrategyawait in interface MainShutdownStrategyInterruptedExceptionpublic void await(long timeout,
TimeUnit unit)
throws InterruptedException
MainShutdownStrategyawait in interface MainShutdownStrategytimeout - the maximum time to waitunit - the time unit of the timeout argumentInterruptedExceptionApache Camel