Top Description Inners Fields Constructors Methods
rx.internal.operators

public final Class SingleOnSubscribeMap<T, R>

extends Object
implements Single.OnSubscribe<R>
Class Inheritance
All Implemented Interfaces
rx.Single.OnSubscribe, rx.functions.Action1, rx.functions.Action, rx.functions.Function
Type Parameters
<T>
the input value type
<R>
the return value type
Imports
rx.*, rx.exceptions.*, rx.functions.Func1, rx.plugins.RxJavaHooks

Applies a function of your choosing to every item emitted by an Single, and emits the results of this transformation as a new Single.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class

Field Summary

Modifier and TypeField and Description
pack-priv final Single<T>
pack-priv final Func1<? super T, ? extends R>

Constructor Summary

AccessConstructor and Description
public
SingleOnSubscribeMap(Single<T> source, Func1<? super T, ? extends R> transformer)

Method Summary

Modifier and TypeMethod and Description
public void
call(final SingleSubscriber<? super R> o)

Implements rx.functions.Action1.call.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

sourceback to summary
pack-priv final Single<T> source
transformerback to summary
pack-priv final Func1<? super T, ? extends R> transformer

Constructor Detail

SingleOnSubscribeMapback to summary
public SingleOnSubscribeMap(Single<T> source, Func1<? super T, ? extends R> transformer)

Method Detail

callback to summary
public void call(final SingleSubscriber<? super R> o)

Implements rx.functions.Action1.call.

Annotations
@Override
rx.internal.operators back to summary

pack-priv final Class SingleOnSubscribeMap.MapSubscriber<T, R>

extends SingleSubscriber<T>
Class Inheritance

Field Summary

Modifier and TypeField and Description
pack-priv final SingleSubscriber<? super R>
pack-priv boolean
pack-priv final Func1<? super T, ? extends R>

Constructor Summary

AccessConstructor and Description
public
MapSubscriber(SingleSubscriber<? super R> actual, Func1<? super T, ? extends R> mapper)

Method Summary

Modifier and TypeMethod and Description
public void
onError(Throwable
the exception encountered by the Single
e
)

Implements abstract rx.SingleSubscriber.onError.

Notifies the SingleSubscriber that the Single has experienced an error condition.
public void
onSuccess(T
the item emitted by the Single
t
)

Implements abstract rx.SingleSubscriber.onSuccess.

Notifies the SingleSubscriber with a single item and that the Single has finished sending push-based notifications.
Inherited from rx.SingleSubscriber:
addisUnsubscribedunsubscribe

Field Detail

actualback to summary
pack-priv final SingleSubscriber<? super R> actual
doneback to summary
pack-priv boolean done
mapperback to summary
pack-priv final Func1<? super T, ? extends R> mapper

Constructor Detail

MapSubscriberback to summary
public MapSubscriber(SingleSubscriber<? super R> actual, Func1<? super T, ? extends R> mapper)

Method Detail

onErrorback to summary
public void onError(Throwable e)

Implements abstract rx.SingleSubscriber.onError.

Doc from rx.SingleSubscriber.onError.

Notifies the SingleSubscriber that the Single has experienced an error condition.

If the Single calls this method, it will not thereafter call onSuccess.

Parameters
e:Throwable

the exception encountered by the Single

Annotations
@Override
onSuccessback to summary
public void onSuccess(T t)

Implements abstract rx.SingleSubscriber.onSuccess.

Doc from rx.SingleSubscriber.onSuccess.

Notifies the SingleSubscriber with a single item and that the Single has finished sending push-based notifications.

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

Parameters
t:T

the item emitted by the Single

Annotations
@Override