Package ai.nexconn.chatui.widget.adapter
Class BaseListViewAdapter
-
- All Implemented Interfaces:
-
android.widget.Adapter,android.widget.ListAdapter,android.widget.SpinnerAdapter
public abstract class BaseListViewAdapter<T> extends BaseAdapter
-
-
Field Summary
Fields Modifier and Type Field Description protected List<T>mListpublic final static intIGNORE_ITEM_VIEW_TYPEpublic final static intNO_SELECTION
-
Constructor Summary
Constructors Constructor Description BaseListViewAdapter()BaseListViewAdapter(Context context)
-
Method Summary
Modifier and Type Method Description <T extends View> TfindViewById(View view, int id)intfindPosition(T message)intfindPosition(long id)voidaddCollection(Collection<T> collection)final voidaddCollection(Array<T> collection)voidadd(T t)voidadd(T t, int position)voidremove(int position)voidremoveAll()voidclear()intgetCount()TgetItem(int position)ViewgetView(int position, View convertView, ViewGroup parent)abstract ViewnewView(Context context, int position, ViewGroup group)abstract voidbindView(View v, int position, T data)-
Methods inherited from class android.widget.BaseAdapter
areAllItemsEnabled, getAutofillOptions, getDropDownView, getItemViewType, getViewTypeCount, hasStableIds, isEmpty, isEnabled, notifyDataSetChanged, notifyDataSetInvalidated, registerDataSetObserver, setAutofillOptions, unregisterDataSetObserver -
Methods inherited from class android.widget.Adapter
getItemId -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
findViewById
<T extends View> T findViewById(View view, int id)
-
findPosition
int findPosition(T message)
-
findPosition
int findPosition(long id)
-
addCollection
void addCollection(Collection<T> collection)
-
addCollection
@SafeVarargs() final void addCollection(Array<T> collection)
-
remove
void remove(int position)
-
removeAll
void removeAll()
-
clear
void clear()
-
getCount
int getCount()
-
getView
View getView(int position, View convertView, ViewGroup parent)
-
newView
abstract View newView(Context context, int position, ViewGroup group)
-
-
-
-