public abstract class BasePresenterActivity<P extends Presenter>
extends AppCompatActivity
| Constructor and Description |
|---|
BasePresenterActivity() |
| Modifier and Type | Method and Description |
|---|---|
void |
destroyPresenter()
Forces the destruction of a presenter.
|
void |
finish() |
P |
getPresenter() |
protected PresenterCache |
getPresenterCache()
Gets the presenter cache.
|
protected abstract void |
injectActivity()
Injects the activity using the a component.
|
protected abstract P |
instantiatePresenter()
This method should return a Presenter instance which will be used for the current view.
|
protected void |
onCreate(android.os.Bundle savedInstanceState) |
protected void |
onPause() |
protected void |
onResume() |
protected void |
onSaveInstanceState(android.os.Bundle outState) |
void |
setPresenterCache(PresenterCache presenterCache)
Injects the presenter cache when child class will inject the activity using
injectActivity(). |
protected void onCreate(android.os.Bundle savedInstanceState)
protected void onSaveInstanceState(android.os.Bundle outState)
protected void onResume()
protected void onPause()
public void finish()
public P getPresenter()
public void destroyPresenter()
public void setPresenterCache(PresenterCache presenterCache)
injectActivity().presenterCache - Presenter cache injected.protected PresenterCache getPresenterCache()
protected abstract void injectActivity()
protected abstract P instantiatePresenter()