Class NewThreadScheduler
java.lang.Object
io.reactivex.rxjava3.core.Scheduler
io.reactivex.rxjava3.internal.schedulers.NewThreadScheduler
Schedules work on a new thread.
-
Nested Class Summary
Nested classes/interfaces inherited from class Scheduler
Scheduler.Worker -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final StringThe name of the system property for setting the thread priority for this Scheduler.private static final RxThreadFactoryprivate static final String(package private) final ThreadFactory -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionRetrieves or creates a newScheduler.Workerthat represents sequential execution of actions.Methods inherited from class Scheduler
clockDriftTolerance, now, scheduleDirect, scheduleDirect, schedulePeriodicallyDirect, shutdown, start, when
-
Field Details
-
threadFactory
-
THREAD_NAME_PREFIX
- See Also:
-
THREAD_FACTORY
-
KEY_NEWTHREAD_PRIORITY
The name of the system property for setting the thread priority for this Scheduler.- See Also:
-
-
Constructor Details
-
NewThreadScheduler
public NewThreadScheduler() -
NewThreadScheduler
-
-
Method Details
-
createWorker
Description copied from class:SchedulerRetrieves or creates a newScheduler.Workerthat represents sequential execution of actions.When work is completed, the
Workerinstance should be released by callingDisposable.dispose()to avoid potential resource leaks in the underlying task-execution scheme.Work on a
Scheduler.Workeris guaranteed to be sequential and non-overlapping.- Specified by:
createWorkerin classScheduler- Returns:
- a Worker representing a serial queue of actions to be executed
-