public class AdapterWrapper
extends android.widget.BaseAdapter
| 构造器和说明 |
|---|
AdapterWrapper(android.widget.ListAdapter wrapped)
Constructor wrapping a supplied ListAdapter
|
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
areAllItemsEnabled()
Are all items in this ListAdapter enabled?
|
int |
getCount()
How many items are in the data set represented by this
Adapter.
|
java.lang.Object |
getItem(int position)
Get the data item associated with the specified
position in the data set.
|
long |
getItemId(int position)
Get the row id associated with the specified position
in the list.
|
int |
getItemViewType(int position)
Get the type of View that will be created by getView()
for the specified item.
|
android.view.View |
getView(int position,
android.view.View convertView,
android.view.ViewGroup parent)
Get a View that displays the data at the specified
position in the data set.
|
int |
getViewTypeCount()
Returns the number of types of Views that will be
created by getView().
|
protected android.widget.ListAdapter |
getWrappedAdapter()
Returns the ListAdapter that is wrapped by the endless
logic.
|
boolean |
hasStableIds()
Get hasStableIds info from wrapped adapter.
|
boolean |
isEmpty() |
boolean |
isEnabled(int position)
Returns true if the item at the specified position is
something selectable.
|
public AdapterWrapper(android.widget.ListAdapter wrapped)
public java.lang.Object getItem(int position)
position - Position of the item whose data we wantpublic int getCount()
public int getViewTypeCount()
getViewTypeCount 在接口中 android.widget.AdaptergetViewTypeCount 在类中 android.widget.BaseAdapterpublic int getItemViewType(int position)
getItemViewType 在接口中 android.widget.AdaptergetItemViewType 在类中 android.widget.BaseAdapterposition - Position of the item whose data we wantpublic boolean hasStableIds()
hasStableIds 在接口中 android.widget.AdapterhasStableIds 在类中 android.widget.BaseAdapterpublic boolean isEmpty()
isEmpty 在接口中 android.widget.AdapterisEmpty 在类中 android.widget.BaseAdapterpublic boolean areAllItemsEnabled()
areAllItemsEnabled 在接口中 android.widget.ListAdapterareAllItemsEnabled 在类中 android.widget.BaseAdapterpublic boolean isEnabled(int position)
isEnabled 在接口中 android.widget.ListAdapterisEnabled 在类中 android.widget.BaseAdapterposition - Position of the item whose data we wantpublic android.view.View getView(int position,
android.view.View convertView,
android.view.ViewGroup parent)
position - Position of the item whose data we wantconvertView - View to recycle, if not nullparent - ViewGroup containing the returned Viewpublic long getItemId(int position)
position - Position of the item whose data we wantprotected android.widget.ListAdapter getWrappedAdapter()