org.springframework.scheduling.timer
Class DelegatingTimerTask
java.lang.Object
java.util.TimerTask
org.springframework.scheduling.timer.DelegatingTimerTask
- All Implemented Interfaces:
- Runnable
public class DelegatingTimerTask
- extends TimerTask
Simple TimerTask adapter that delegates to a given Runnable.
This is often preferable to deriving from TimerTask, to be able to
implement an interface rather than extend an abstract base class.
- Since:
- 1.2.4
- Author:
- Juergen Hoeller
- See Also:
TimerTask
,
Runnable
Method Summary |
void |
run()
Delegates execution to the underlying Runnable. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DelegatingTimerTask
public DelegatingTimerTask(Runnable runnable)
- Create a new DelegatingTimerTask.
- Parameters:
runnable
- the Runnable implementation to delegate to
run
public void run()
- Delegates execution to the underlying Runnable.
- Specified by:
run
in interface Runnable
- Specified by:
run
in class TimerTask
Copyright (c) 2002-2007 The Spring Framework Project.