spring-context

org.springframework.scheduling.timer
Class MethodInvokingTimerTaskFactoryBean

java.lang.Object
  extended by org.springframework.util.MethodInvoker
      extended by org.springframework.beans.support.ArgumentConvertingMethodInvoker
          extended by org.springframework.scheduling.support.MethodInvokingRunnable
              extended by org.springframework.scheduling.timer.MethodInvokingTimerTaskFactoryBean
All Implemented Interfaces:
java.lang.Runnable, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.beans.factory.FactoryBean<java.util.TimerTask>, org.springframework.beans.factory.InitializingBean

Deprecated. as of Spring 3.0, in favor of the scheduling.concurrent package which is based on Java 5's java.util.concurrent.ExecutorService

@Deprecated
public class MethodInvokingTimerTaskFactoryBean
extends MethodInvokingRunnable
implements org.springframework.beans.factory.FactoryBean<java.util.TimerTask>

FactoryBean that exposes a TimerTask object which delegates job execution to a specified (static or non-static) method. Avoids the need to implement a one-line TimerTask that just invokes an existing business method.

Derives from MethodInvokingRunnable to share common properties and behavior, effectively providing a TimerTask adapter for it.

Since:
19.02.2004
Author:
Juergen Hoeller
See Also:
DelegatingTimerTask, ScheduledTimerTask.setTimerTask(java.util.TimerTask), ScheduledTimerTask.setRunnable(java.lang.Runnable), MethodInvokingRunnable, MethodInvokingFactoryBean

Field Summary
 
Fields inherited from class org.springframework.scheduling.support.MethodInvokingRunnable
logger
 
Constructor Summary
MethodInvokingTimerTaskFactoryBean()
          Deprecated.  
 
Method Summary
 void afterPropertiesSet()
          Deprecated.  
 java.util.TimerTask getObject()
          Deprecated.  
 java.lang.Class<java.util.TimerTask> getObjectType()
          Deprecated.  
 boolean isSingleton()
          Deprecated.  
 
Methods inherited from class org.springframework.scheduling.support.MethodInvokingRunnable
getInvocationFailureMessage, resolveClassName, run, setBeanClassLoader
 
Methods inherited from class org.springframework.beans.support.ArgumentConvertingMethodInvoker
doFindMatchingMethod, findMatchingMethod, getDefaultTypeConverter, getTypeConverter, registerCustomEditor, setTypeConverter
 
Methods inherited from class org.springframework.util.MethodInvoker
getArguments, getPreparedMethod, getTargetClass, getTargetMethod, getTargetObject, getTypeDifferenceWeight, invoke, isPrepared, prepare, setArguments, setStaticMethod, setTargetClass, setTargetMethod, setTargetObject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MethodInvokingTimerTaskFactoryBean

public MethodInvokingTimerTaskFactoryBean()
Deprecated. 
Method Detail

afterPropertiesSet

public void afterPropertiesSet()
                        throws java.lang.ClassNotFoundException,
                               java.lang.NoSuchMethodException
Deprecated. 
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
Overrides:
afterPropertiesSet in class MethodInvokingRunnable
Throws:
java.lang.ClassNotFoundException
java.lang.NoSuchMethodException

getObject

public java.util.TimerTask getObject()
Deprecated. 
Specified by:
getObject in interface org.springframework.beans.factory.FactoryBean<java.util.TimerTask>

getObjectType

public java.lang.Class<java.util.TimerTask> getObjectType()
Deprecated. 
Specified by:
getObjectType in interface org.springframework.beans.factory.FactoryBean<java.util.TimerTask>

isSingleton

public boolean isSingleton()
Deprecated. 
Specified by:
isSingleton in interface org.springframework.beans.factory.FactoryBean<java.util.TimerTask>

spring-context