Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.ignoreElements() Change return type #1436

Closed
gorozco58 opened this issue Oct 4, 2017 · 2 comments
Closed

.ignoreElements() Change return type #1436

gorozco58 opened this issue Oct 4, 2017 · 2 comments

Comments

@gorozco58
Copy link

Description:

I am trying to use .ignoreElements() method due to I have a method returning a Observable<Type>and I wanna transform this into Completable trait but .ignoreElements() return RxSwift.Observable<Self.E>.

Expected outcome:

I have been looking for another Rx implementations and this method return Completable.
I think this make sense because I just want onComplete or onError event .

What actually happens:

The method is currently returning RxSwift.Observable<Self.E>.

Java Implementation:

This is the Java implementation.

/**
     * Ignores all items emitted by the source ObservableSource and only calls {@code onComplete} or {@code onError}.
     * <p>
     * <img width="640" height="305" src="https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/ignoreElements.2.png" alt="">
     * <dl>
     *  <dt><b>Scheduler:</b></dt>
     *  <dd>{@code ignoreElements} does not operate by default on a particular {@link Scheduler}.</dd>
     * </dl>
     *
     * @return the new Completable instance
     * @see <a href="http://reactivex.io/documentation/operators/ignoreelements.html">ReactiveX operators documentation: IgnoreElements</a>
     */
    @CheckReturnValue
    @SchedulerSupport(SchedulerSupport.NONE)
    public final Completable ignoreElements() {
        return RxJavaPlugins.onAssembly(new ObservableIgnoreElementsCompletable<T>(this));
    }
@kzaher
Copy link
Member

kzaher commented Oct 5, 2017

Hi @gorozco58 ,

yes, I think we can change the return type now.

@kzaher
Copy link
Member

kzaher commented Oct 7, 2017

This should be fixed now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants