Class SearchAdapter
- java.lang.Object
-
- android.widget.BaseAdapter
-
- android.widget.ArrayAdapter<Product>
-
- edu.cnm.deepdive.albuquirky.adapter.SearchAdapter
-
- All Implemented Interfaces:
Adapter,Filterable,ListAdapter,SpinnerAdapter,ThemedSpinnerAdapter
public class SearchAdapter extends ArrayAdapter<Product>
Adapter class for theBrowserFragment.
-
-
Field Summary
-
Fields inherited from interface android.widget.Adapter
IGNORE_ITEM_VIEW_TYPE, NO_SELECTION
-
-
Constructor Summary
Constructors Constructor Description SearchAdapter(Context context, List<Product> products)The constructor sets a value for the requiredLayoutInflaterand aNumberFormatto properly format product prices as currency.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ViewgetView(int position, View convertView, ViewGroup parent)-
Methods inherited from class android.widget.ArrayAdapter
add, addAll, addAll, clear, createFromResource, getAutofillOptions, getContext, getCount, getDropDownView, getDropDownViewTheme, getFilter, getItem, getItemId, getPosition, insert, notifyDataSetChanged, remove, setDropDownViewResource, setDropDownViewTheme, setNotifyOnChange, sort
-
Methods inherited from class android.widget.BaseAdapter
areAllItemsEnabled, getItemViewType, getViewTypeCount, hasStableIds, isEmpty, isEnabled, notifyDataSetInvalidated, registerDataSetObserver, setAutofillOptions, unregisterDataSetObserver
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface android.widget.Adapter
getItemViewType, getViewTypeCount, hasStableIds, isEmpty, registerDataSetObserver, unregisterDataSetObserver
-
-
-
-
Constructor Detail
-
SearchAdapter
public SearchAdapter(@NonNull Context context, @NonNull List<Product> products)
The constructor sets a value for the requiredLayoutInflaterand aNumberFormatto properly format product prices as currency.- Parameters:
context- The application context.products- A list ofProductobjects to display.
-
-