## 接口的使用
org.springframework.scheduling.TaskScheduler

- 使用TaskScheduler的程序包
  程序包 | 说明
  --- | ---
  org.springframework.scheduling.concurrent | Scheduling convenience classes for the `java.util.concurrent` and `javax.enterprise.concurrent` packages, allowing to set up a ThreadPoolExecutor or ScheduledThreadPoolExecutor as a bean in a Spring context.
  org.springframework.scheduling.config | Support package for declarative scheduling configuration, with XML schema being the primary configuration format.

- - ### org.springframework.scheduling.concurrent中TaskScheduler的使用

    实现TaskScheduler的org.springframework.scheduling.concurrent中的类
    限定符和类型 | 类和说明
    --- | ---
    `class` | `ConcurrentTaskScheduler` Adapter that takes a `java.util.concurrent.ScheduledExecutorService` and exposes a Spring `TaskScheduler` for it.
    `class` | `DefaultManagedTaskScheduler` JNDI-based variant of `ConcurrentTaskScheduler`, performing a default lookup for JSR-236's "java:comp/DefaultManagedScheduledExecutorService" in a Java EE 7 environment.
    `class` | `ThreadPoolTaskScheduler` Implementation of Spring's `TaskScheduler` interface, wrapping a native `ScheduledThreadPoolExecutor`.

  - ### org.springframework.scheduling.config中TaskScheduler的使用

    返回TaskScheduler的org.springframework.scheduling.config中的方法
    限定符和类型 | 方法和说明
    --- | ---
    `TaskScheduler` | ScheduledTaskRegistrar.`getScheduler()` Return the `TaskScheduler` instance for this registrar (may be `null`).

    参数类型为TaskScheduler的org.springframework.scheduling.config中的方法
    限定符和类型 | 方法和说明
    --- | ---
    `void` | ScheduledTaskRegistrar.`setTaskScheduler(TaskScheduler taskScheduler)` Set the `TaskScheduler` to register scheduled tasks with.