public class SingleStateStrategy extends java.lang.Object implements StateStrategy
| Constructor and Description |
|---|
SingleStateStrategy() |
| Modifier and Type | Method and Description |
|---|---|
<View extends MvpView> |
afterApply(java.util.List<ViewCommand<View>> currentState,
ViewCommand<View> incomingCommand)
Called immediately after command applied to
MvpView. |
<View extends MvpView> |
beforeApply(java.util.List<ViewCommand<View>> currentState,
ViewCommand<View> incomingCommand)
Called immediately after
MvpViewState receive some
command. |
public <View extends MvpView> void beforeApply(java.util.List<ViewCommand<View>> currentState, ViewCommand<View> incomingCommand)
StateStrategyMvpViewState receive some
command. Will not be called before re-apply to some other
MvpViewbeforeApply in interface StateStrategyView - type of incoming viewcurrentState - current state of
MvpViewState. Each ViewCommand
contains self parameters.incomingCommand - command for apply to MvpView This
ViewCommand contains params of this command.public <View extends MvpView> void afterApply(java.util.List<ViewCommand<View>> currentState, ViewCommand<View> incomingCommand)
StateStrategyMvpView. Also called
after re-apply to other views.afterApply in interface StateStrategyView - type of incoming viewcurrentState - current state of
MvpViewState. Each ViewCommand
contains self parameters.incomingCommand - applied command to MvpView This
ViewCommand contains params of this command.