Code example for CursorAdapter

Methods: notifyDataSetChanged, getItem

0
    } 
 
    /** {@inheritDoc} */ 
    @Override 
    public void onListItemClick(ListView l, View v, int position, long id) {
        final Cursor cursor = (Cursor) mAdapter.getItem(position);
        String vendorId = cursor.getString(VendorsQuery.VENDOR_ID);
        if (mCallbacks.onVendorSelected(vendorId)) {
            mSelectedVendorId = vendorId;
            mAdapter.notifyDataSetChanged();
        } 
    } 
 
    @Override 
    public Loader<Cursor> onCreateLoader(int id, Bundle data) {
        return new CursorLoader(getActivity(), mVendorsUri, VendorsQuery.PROJECTION, null, null,
                ScheduleContract.Vendors.DEFAULT_SORT); 
    } 
 
    @Override 
    public void onLoadFinished(Loader<Cursor> loader, Cursor cursor) {