| java.lang.Object | |
| ↳ | com.h6ah4i.android.widget.advrecyclerview.event.BaseRecyclerViewEventDistributor<T> |
Known Direct Subclasses
|
| Fields | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| protected List<T> | mListeners | ||||||||||
| protected boolean | mPerformingClearMethod | ||||||||||
| protected RecyclerView | mRecyclerView | ||||||||||
| protected boolean | mReleased | ||||||||||
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| BaseRecyclerViewEventDistributor() | |||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| boolean |
add(T listener)
Add a T listener to the chain.
| ||||||||||
| boolean |
add(T listener, int index)
Add a T listener to the chain at the specified position.
| ||||||||||
| void |
attachRecyclerView(RecyclerView rv)
Attaches android.support.v7.widget.RecyclerView instance.
| ||||||||||
| void |
clear()
Remove all listeners from the chain.
| ||||||||||
| boolean |
contains(T listener)
Gets whether the specified listener object is contained in the chain.
| ||||||||||
| RecyclerView |
getRecyclerView()
Gets attached android.support.v7.widget.RecyclerView
| ||||||||||
| boolean |
isReleased()
Indicates whether this distributor has been released
| ||||||||||
| void |
release()
Release all references.
| ||||||||||
| boolean |
remove(T listener)
Remove a T listener from the chain.
| ||||||||||
| int |
size()
Gets the number of underlying listener objects.
| ||||||||||
| Protected Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| void | clear(boolean calledFromRelease) | ||||||||||
| void | onRecyclerViewAttached(RecyclerView rv) | ||||||||||
| void | onRelease() | ||||||||||
| void | verifyIsNotPerformingClearMethod(String methodName) | ||||||||||
| void | verifyIsNotReleased(String methodName) | ||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
Add a T listener to the chain.
| listener | The T instance |
|---|
Add a T listener to the chain at the specified position.
| listener | The T instance |
|---|---|
| index | Position in the listener chain to insert this listener at. (< 0: tail of the chain) |
Attaches android.support.v7.widget.RecyclerView instance.
| rv | The android.support.v7.widget.RecyclerView instance |
|---|
Remove all listeners from the chain.
Gets whether the specified listener object is contained in the chain.
| listener | Listener to check |
|---|
Gets attached android.support.v7.widget.RecyclerView
Indicates whether this distributor has been released
Release all references. This method should be called to avoid memory leaks.
Remove a T listener from the chain.
| listener | Listener to remove |
|---|
Gets the number of underlying listener objects.