类 ScheduledMethodRunnable

java.lang.Object
cn.taketoday.scheduling.support.ScheduledMethodRunnable
所有已实现的接口:
Runnable

public class ScheduledMethodRunnable extends Object implements Runnable
Variant of MethodInvokingRunnable meant to be used for processing of no-arg scheduled methods. Propagates user exceptions to the caller, assuming that an error strategy for Runnables is in place.
作者:
Juergen Hoeller
另请参阅:
  • 构造器详细资料

    • ScheduledMethodRunnable

      public ScheduledMethodRunnable(Object target, Method method)
      Create a ScheduledMethodRunnable for the given target instance, calling the specified method.
      参数:
      target - the target instance to call the method on
      method - the target method to call
    • ScheduledMethodRunnable

      public ScheduledMethodRunnable(Object target, String methodName) throws NoSuchMethodException
      Create a ScheduledMethodRunnable for the given target instance, calling the specified method by name.
      参数:
      target - the target instance to call the method on
      methodName - the name of the target method
      抛出:
      NoSuchMethodException - if the specified method does not exist
  • 方法详细资料

    • getTarget

      public Object getTarget()
      Return the target instance to call the method on.
    • getMethod

      public Method getMethod()
      Return the target method to call.
    • run

      public void run()
      指定者:
      run 在接口中 Runnable
    • toString

      public String toString()
      覆盖:
      toString 在类中 Object