- Enclosing interface:
- TaskScheduler
public static interface TaskScheduler.Builder
A builder for
TaskScheduler
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
initialDelay
(int initialDelay) start()
Builds and starts a newTaskScheduler
.threadFactory
(ThreadFactory threadFactory)
-
Method Details
-
interval
- Parameters:
interval
- the intervaltimeUnit
- the time unit- Returns:
- this builder instance
-
initialDelay
- Parameters:
initialDelay
- the initial start delay, used on restarts as well- Returns:
- this builder instance
-
threadFactory
- Parameters:
threadFactory
- the thread factory to use- Returns:
- this builder instance
-
start
TaskScheduler start()Builds and starts a newTaskScheduler
.- Returns:
- a new
TaskScheduler
.
-
build
TaskScheduler build()- Returns:
- a new
TaskScheduler
.
-