Class TimerLifecycle
- java.lang.Object
- 
- java.util.Timer
- 
- org.eclipse.net4j.util.concurrent.TimerLifecycle
 
 
- 
- All Implemented Interfaces:
- INotifier,- IDeactivateable,- ILifecycle
 
 public class TimerLifecycle extends java.util.Timer implements ILifecycle - Since:
- 2.0
- Author:
- Eike Stepper
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classTimerLifecycle.DaemonFactory- 
Nested classes/interfaces inherited from interface org.eclipse.net4j.util.lifecycle.ILifecycleILifecycle.DeferrableActivation
 - 
Nested classes/interfaces inherited from interface org.eclipse.net4j.util.event.INotifierINotifier.INotifier2
 
- 
 - 
Field SummaryFields Modifier and Type Field Description static java.lang.StringPRODUCT_GROUP
 - 
Constructor SummaryConstructors Constructor Description TimerLifecycle()TimerLifecycle(boolean isDaemon)TimerLifecycle(java.lang.String name)TimerLifecycle(java.lang.String name, boolean isDaemon)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidactivate()voidaddListener(IListener listener)Adds a listener to this notifier.voidcancel()java.lang.Exceptiondeactivate()LifecycleStategetLifecycleState()IListener[]getListeners()Returns the listeners that are registered with this notifier.booleanhasListeners()Returnstrueif one or more listeners are registered with this notifier,falseotherwise.booleanisActive()voidremoveListener(IListener listener)Removes a listener from this notifier.java.lang.StringtoString()
 
- 
- 
- 
Field Detail- 
PRODUCT_GROUPpublic static final java.lang.String PRODUCT_GROUP - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
getLifecycleStatepublic final LifecycleState getLifecycleState() - Specified by:
- getLifecycleStatein interface- ILifecycle
- Since:
- 3.0
 
 - 
isActivepublic final boolean isActive() - Specified by:
- isActivein interface- ILifecycle
 
 - 
addListenerpublic void addListener(IListener listener) Description copied from interface:INotifierAdds a listener to this notifier.Depending on the implementation duplicate listeners may lead to duplicate event delivery or not. Implementors are encouraged to prevent events from being delivered more than once to the same listener, - Specified by:
- addListenerin interface- INotifier
 
 - 
removeListenerpublic void removeListener(IListener listener) Description copied from interface:INotifierRemoves a listener from this notifier.- Specified by:
- removeListenerin interface- INotifier
 
 - 
getListenerspublic IListener[] getListeners() Description copied from interface:INotifierReturns the listeners that are registered with this notifier.Depending on the implementation duplicate listeners may be contained in the returned array. - Specified by:
- getListenersin interface- INotifier
 
 - 
hasListenerspublic boolean hasListeners() Description copied from interface:INotifierReturnstrueif one or more listeners are registered with this notifier,falseotherwise.- Specified by:
- hasListenersin interface- INotifier
 
 - 
activatepublic final void activate() throws LifecycleException- Specified by:
- activatein interface- ILifecycle
- Throws:
- LifecycleException
 
 - 
deactivatepublic final java.lang.Exception deactivate() - Specified by:
- deactivatein interface- IDeactivateable
- Specified by:
- deactivatein interface- ILifecycle
 
 - 
toStringpublic java.lang.String toString() - Overrides:
- toStringin class- java.lang.Object
 
 - 
cancelpublic void cancel() - Overrides:
- cancelin class- java.util.Timer
 
 
- 
 
-