Search in sources :

Example 11 with CompositeSubscription

use of rx.subscriptions.CompositeSubscription in project ListenerMusicPlayer by hefuyicoder.

the class ArtistDetailPresenter method attachView.

@Override
public void attachView(ArtistDetailContract.View view) {
    mView = view;
    mCompositeSubscription = new CompositeSubscription();
}
Also used : CompositeSubscription(rx.subscriptions.CompositeSubscription)

Example 12 with CompositeSubscription

use of rx.subscriptions.CompositeSubscription in project ListenerMusicPlayer by hefuyicoder.

the class RxBus method addSubscription.

/**
     * 保存订阅后的subscription
     * @param o
     * @param subscription
     */
public void addSubscription(Object o, Subscription subscription) {
    if (mSubscriptionMap == null) {
        mSubscriptionMap = new HashMap<>();
    }
    String key = o.getClass().getName();
    if (mSubscriptionMap.get(key) != null) {
        mSubscriptionMap.get(key).add(subscription);
    } else {
        CompositeSubscription compositeSubscription = new CompositeSubscription();
        compositeSubscription.add(subscription);
        mSubscriptionMap.put(key, compositeSubscription);
    }
}
Also used : CompositeSubscription(rx.subscriptions.CompositeSubscription)

Example 13 with CompositeSubscription

use of rx.subscriptions.CompositeSubscription in project ListenerMusicPlayer by hefuyicoder.

the class ArtistPresenter method attachView.

@Override
public void attachView(ArtistContract.View view) {
    mView = view;
    mCompositeSubscription = new CompositeSubscription();
}
Also used : CompositeSubscription(rx.subscriptions.CompositeSubscription)

Example 14 with CompositeSubscription

use of rx.subscriptions.CompositeSubscription in project ListenerMusicPlayer by hefuyicoder.

the class FolderSongsPresenter method attachView.

@Override
public void attachView(FolderSongsContract.View view) {
    mView = view;
    mCompositeSubscription = new CompositeSubscription();
}
Also used : CompositeSubscription(rx.subscriptions.CompositeSubscription)

Example 15 with CompositeSubscription

use of rx.subscriptions.CompositeSubscription in project ListenerMusicPlayer by hefuyicoder.

the class PlayRankingPresenter method attachView.

@Override
public void attachView(PlayRankingContract.View view) {
    mView = view;
    mCompositeSubscription = new CompositeSubscription();
}
Also used : CompositeSubscription(rx.subscriptions.CompositeSubscription)

Aggregations

CompositeSubscription (rx.subscriptions.CompositeSubscription)49 ArrayList (java.util.ArrayList)9 View (android.view.View)7 Subscription (rx.Subscription)7 Context (android.content.Context)6 Bundle (android.os.Bundle)6 AndroidSchedulers (rx.android.schedulers.AndroidSchedulers)6 Intent (android.content.Intent)5 AppCompatActivity (android.support.v7.app.AppCompatActivity)5 RecyclerView (android.support.v7.widget.RecyclerView)5 ViewGroup (android.view.ViewGroup)5 List (java.util.List)5 Schedulers (rx.schedulers.Schedulers)5 MenuItem (android.view.MenuItem)4 Issue (com.kboyarshinov.realmrxjavaexample.model.Issue)4 ActionBar (android.support.v7.app.ActionBar)3 LinearLayoutManager (android.support.v7.widget.LinearLayoutManager)3 Menu (android.view.Menu)3 TextView (android.widget.TextView)3 TwitterStringUtils (com.github.moko256.twicalico.text.TwitterStringUtils)3