public static class ListRowPresenter.SelectItemViewHolderTask extends Presenter.ViewHolderTask
Constructor and Description |
---|
SelectItemViewHolderTask(int itemPosition) |
Modifier and Type | Method and Description |
---|---|
int |
getItemPosition()
Returns the adapter position of item to select.
|
Presenter.ViewHolderTask |
getItemTask()
Returns optional task to run when the item is selected, null for no task.
|
boolean |
isSmoothScroll()
Returns true if smooth scrolling to the item false otherwise.
|
void |
run(Presenter.ViewHolder holder)
Called to perform a task on view holder.
|
void |
setItemPosition(int itemPosition)
Sets the adapter position of item to select.
|
void |
setItemTask(Presenter.ViewHolderTask itemTask)
Sets task to run when the item is selected, null for no task.
|
void |
setSmoothScroll(boolean smoothScroll)
Sets smooth scrolling to the item or jump to the item without scrolling.
|
public void setItemPosition(int itemPosition)
itemPosition
- Position of the item in adapter.public int getItemPosition()
public void setSmoothScroll(boolean smoothScroll)
smoothScroll
- True for smooth scrolling to the item, false otherwise.public boolean isSmoothScroll()
public Presenter.ViewHolderTask getItemTask()
public void setItemTask(Presenter.ViewHolderTask itemTask)
itemTask
- Optional task to run when the item is selected, null for no task.public void run(Presenter.ViewHolder holder)
Presenter.ViewHolderTask
run
in class Presenter.ViewHolderTask
holder
- The view holder to perform task.