@author: liaojinlong @date: 2020/6/9 17:02 @since: 1.0 @see SpringContextHolder 针对某些初始化方法,在SpringContextHolder 初始化前时, 可提交一个 提交回调任务。 在SpringContextHolder 初始化后,进行回调使用
| 27 | */ |
| 28 | |
| 29 | public interface CallBack { |
| 30 | /** |
| 31 | * 回调执行方法 |
| 32 | */ |
| 33 | void executor(); |
| 34 | |
| 35 | /** |
| 36 | * 本回调任务名称 |
| 37 | * @return / |
| 38 | */ |
| 39 | default String getCallBackName() { |
| 40 | return Thread.currentThread().getId() + ":" + this.getClass().getName(); |
| 41 | } |
| 42 | } |
| 43 |
no outgoing calls
no test coverage detected