Interface TimerFactory

All Known Implementing Classes:
SingletonTimerFactory

public interface TimerFactory
This class provides access to Timer objects for various purposes. The scheme for creation of Timer objects is implementation-defined.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Cancel a task.
    void
    schedule(TimerTask task, long delay)
    Schedule a task.
  • Method Details

    • schedule

      void schedule(TimerTask task, long delay)
      Schedule a task.
      Parameters:
      task - the task to schedule
      delay - how many milliseconds to wait before executing the task
    • cancel

      void cancel(TimerTask task)
      Cancel a task.
      Parameters:
      task - the task to cancel