class ReportTooltipPresenter extends BaseViperPresenter<LegacyTooltipView, ReportTooltipInteractor<? extends FragmentActivity>> implements BackupProviderChangeListener {

    @Override
    public void subscribe() {
        backupProvidersManager.registerChangeListener(this);
        updateProvider(backupProvidersManager.getSyncProvider());

        compositeDisposable.add(interactor.checkTooltipCauses()
                .subscribeOn(subscribeOnScheduler)
                .observeOn(observeOnScheduler)
                .subscribe(view::present));

        compositeDisposable.add(view.getTooltipsClicks()
                .doOnNext(uiIndicator -> {
                    Logger.info(ReportTooltipPresenter.this, "User clicked on {} tooltip", uiIndicator);
                    if (uiIndicator.getState() == ReportTooltipUiIndicator.State.GenerateInfo) {
                        analytics.record(Events.Informational.ClickedGenerateReportTip);
                    } else if (uiIndicator.getState() == ReportTooltipUiIndicator.State.BackupReminder) {
                        analytics.record(Events.Informational.ClickedBackupReminderTip);
                    }
                })
                .subscribe(uiIndicator -> {
                    view.present(ReportTooltipUiIndicator.none());
                    if (uiIndicator.getState() == ReportTooltipUiIndicator.State.SyncError) {
                        interactor.handleClickOnErrorTooltip(uiIndicator.getErrorType().get());
                    } else if (uiIndicator.getState() == ReportTooltipUiIndicator.State.GenerateInfo) {
                        // Note: The actual click logic is in the view (probably need to clean up dagger for this to be cleaner)
                        interactor.generateInfoTooltipClosed();
                    } else if (uiIndicator.getState() == ReportTooltipUiIndicator.State.BackupReminder) {
                        interactor.backupReminderTooltipClosed();
                    }
                }));

        compositeDisposable.add(view.getCloseButtonClicks()
                .subscribe(uiIndicator -> {
                    view.present(ReportTooltipUiIndicator.none());
                    if (uiIndicator.getState() == ReportTooltipUiIndicator.State.GenerateInfo) {
                        interactor.generateInfoTooltipClosed();
                    } else if (uiIndicator.getState() == ReportTooltipUiIndicator.State.BackupReminder) {
                        interactor.backupReminderTooltipClosed();
                    } else if (uiIndicator.getState() == ReportTooltipUiIndicator.State.ImportInfo) {
                        interactor.importInfoTooltipClosed();
                    }
                }));
    }

    @SuppressWarnings("unchecked") @Inject public  ReportTooltipPresenter(@NonNull LegacyTooltipView view,
                                  @NonNull ReportTooltipInteractor interactor,
                                  @NonNull BackupProvidersManager backupProvidersManager,
                                  @NonNull Analytics analytics);
    @SuppressWarnings("unchecked") public  ReportTooltipPresenter(@NonNull LegacyTooltipView view,
                                  @NonNull ReportTooltipInteractor interactor,
                                  @NonNull BackupProvidersManager backupProvidersManager,
                                  @NonNull Analytics analytics,
                                  @NonNull Scheduler subscribeOnScheduler,
                                  @NonNull Scheduler observeOnScheduler);

}