public class RecyclerSwipeSquareAdapter
extends android.support.v7.widget.RecyclerView.Adapter
| Modifier and Type | Class and Description |
|---|---|
static class |
RecyclerSwipeSquareAdapter.SquareViewHolder |
| Modifier and Type | Field and Description |
|---|---|
private Context |
context |
(package private) int |
i |
static java.lang.String |
NOTIFICATION_MAP |
java.util.ArrayList<Square> |
squaresArrayList |
private static java.lang.String |
TAG |
| Constructor and Description |
|---|
RecyclerSwipeSquareAdapter(Context c,
java.util.ArrayList<Square> squares) |
| Modifier and Type | Method and Description |
|---|---|
private void |
favouriteSquare(int method,
Square square) |
int |
getItemCount() |
long |
getItemId(int position) |
void |
onBindViewHolder(android.support.v7.widget.RecyclerView.ViewHolder holder,
int position) |
RecyclerSwipeSquareAdapter.SquareViewHolder |
onCreateViewHolder(ViewGroup parent,
int viewType) |
void |
removeElement(int position) |
private void |
setupHeart(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder,
Square listItem) |
private void |
setupLeftSection(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder,
java.lang.String initials) |
private void |
setupNotifications(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder,
Square listItem) |
private void |
setupSwipeLayout(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder,
Square square) |
bindViewHolder, createViewHolder, getItemViewType, hasObservers, hasStableIds, notifyDataSetChanged, notifyItemChanged, notifyItemChanged, notifyItemInserted, notifyItemMoved, notifyItemRangeChanged, notifyItemRangeChanged, notifyItemRangeInserted, notifyItemRangeRemoved, notifyItemRemoved, onAttachedToRecyclerView, onBindViewHolder, onDetachedFromRecyclerView, onFailedToRecycleView, onViewAttachedToWindow, onViewDetachedFromWindow, onViewRecycled, registerAdapterDataObserver, setHasStableIds, unregisterAdapterDataObserverprivate static final java.lang.String TAG
public static final java.lang.String NOTIFICATION_MAP
private Context context
public java.util.ArrayList<Square> squaresArrayList
int i
public RecyclerSwipeSquareAdapter(Context c,
java.util.ArrayList<Square> squares)
public RecyclerSwipeSquareAdapter.SquareViewHolder onCreateViewHolder(ViewGroup parent, int viewType)
onCreateViewHolder in class android.support.v7.widget.RecyclerView.Adapterpublic void onBindViewHolder(android.support.v7.widget.RecyclerView.ViewHolder holder,
int position)
onBindViewHolder in class android.support.v7.widget.RecyclerView.Adapterprivate void setupSwipeLayout(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder, Square square)
private void setupLeftSection(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder, java.lang.String initials)
private void setupHeart(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder, Square listItem)
public void removeElement(int position)
private void setupNotifications(RecyclerSwipeSquareAdapter.SquareViewHolder castHolder, Square listItem)
public long getItemId(int position)
getItemId in class android.support.v7.widget.RecyclerView.Adapterpublic int getItemCount()
getItemCount in class android.support.v7.widget.RecyclerView.Adapterprivate void favouriteSquare(int method,
Square square)