Top Description Methods
rx

public Interface CompletableEmitter

Known Direct Implementers
rx.internal.operators.CompletableFromEmitter.FromEmitter
Imports
rx.functions.Cancellable

Abstraction over a CompletableSubscriber that gets either an onCompleted or onError signal and allows registering an cancellation/unsubscription callback.

All methods are thread-safe; calling onCompleted or onError twice or one after the other has no effect.

Since
1.3

Method Summary

Modifier and TypeMethod and Description
public void
onCompleted()

Notifies the CompletableSubscriber that the Completable has finished sending push-based notifications.

public void
onError(Throwable
the exception encountered by the Observable
t
)

Notifies the CompletableSubscriber that the Completable has experienced an error condition.

public void
setCancellation(Cancellable
the cancellable resource, null is allowed
c
)

Sets a Cancellable on this emitter; any previous Subscription or Cancellation will be unsubscribed/cancelled.

public void
setSubscription(Subscription
the subscription, null is allowed
s
)

Sets a Subscription on this emitter; any previous Subscription or Cancellation will be unsubscribed/cancelled.

Method Detail

onCompletedback to summary
public void onCompleted()

Notifies the CompletableSubscriber that the Completable has finished sending push-based notifications.

The Observable will not call this method if it calls onError.

onErrorback to summary
public void onError(Throwable t)

Notifies the CompletableSubscriber that the Completable has experienced an error condition.

If the Completable calls this method, it will not thereafter call onCompleted.

Parameters
t:Throwable

the exception encountered by the Observable

setCancellationback to summary
public void setCancellation(Cancellable c)

Sets a Cancellable on this emitter; any previous Subscription or Cancellation will be unsubscribed/cancelled.

Parameters
c:Cancellable

the cancellable resource, null is allowed

setSubscriptionback to summary
public void setSubscription(Subscription s)

Sets a Subscription on this emitter; any previous Subscription or Cancellation will be unsubscribed/cancelled.

Parameters
s:Subscription

the subscription, null is allowed