RxJava



rx.schedulers
Class ImmediateScheduler

java.lang.Object
  extended by rx.Scheduler
      extended by rx.schedulers.ImmediateScheduler

public final class ImmediateScheduler
extends Scheduler

Executes work immediately on the current thread.


Nested Class Summary
 
Nested classes/interfaces inherited from class rx.Scheduler
Scheduler.Inner, Scheduler.Recurse
 
Method Summary
static ImmediateScheduler getInstance()
          Deprecated. Use Schedulers.immediate();
 Subscription schedule(Action1<Scheduler.Inner> action)
          Schedules an Action on a new Scheduler instance (typically another thread) for execution.
 Subscription schedule(Action1<Scheduler.Inner> action, long delayTime, java.util.concurrent.TimeUnit unit)
          Schedules an Action on a new Scheduler instance (typically another thread) for execution at some point in the future.
 
Methods inherited from class rx.Scheduler
degreeOfParallelism, now, schedulePeriodically, scheduleRecursive
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

@Deprecated
public static ImmediateScheduler getInstance()
Deprecated. Use Schedulers.immediate();

Returns:

schedule

public Subscription schedule(Action1<Scheduler.Inner> action)
Description copied from class: Scheduler
Schedules an Action on a new Scheduler instance (typically another thread) for execution.

Specified by:
schedule in class Scheduler
Parameters:
action - Action to schedule
Returns:
a subscription to be able to unsubscribe from action

schedule

public Subscription schedule(Action1<Scheduler.Inner> action,
                             long delayTime,
                             java.util.concurrent.TimeUnit unit)
Description copied from class: Scheduler
Schedules an Action on a new Scheduler instance (typically another thread) for execution at some point in the future.

Specified by:
schedule in class Scheduler
Parameters:
action - the Action to schedule
delayTime - time to wait before executing the action
unit - the time unit the delay time is given in
Returns:
a subscription to be able to unsubscribe from action