Code example for ContentResolver

Methods: query

0
	} 
 
    @Override 
    protected void refreshStories() { 
        Uri storiesUri = FeedProvider.FEED_STORIES_URI.buildUpon().appendPath(feedId).build();
        Cursor cursor = contentResolver.query(storiesUri, null, DatabaseConstants.getStorySelectionFromState(currentState), null, DatabaseConstants.getStorySortOrder(storyOrder));
        adapter.swapCursor(cursor);
    } 
 
	@Override 
	public void onScroll(AbsListView view, int firstVisible, int visibleCount, int totalCount) {
		if (firstVisible + visibleCount == totalCount && !requestedPage) {
			currentPage += 1;
			requestedPage = true;
			((ItemsList) getActivity()).triggerRefresh(currentPage);
		} 
	} 
 
	@Override 
	public void onScrollStateChanged(AbsListView view, int scrollState) { }