/frameworks/base/cmds/content/src/com/android/commands/content/ |
H A D | Content.java | 474 Cursor cursor = provider.query(null, mUri, mProjection, mWhere, null, mSortOrder, null); 475 if (cursor == null) { 480 if (cursor.moveToFirst()) { 487 final int columnCount = cursor.getColumnCount(); 492 String columnName = cursor.getColumnName(i); 494 final int columnIndex = cursor.getColumnIndex(columnName); 495 final int type = cursor.getType(columnIndex); 498 columnValue = String.valueOf(cursor.getFloat(columnIndex)); 501 columnValue = String.valueOf(cursor.getInt(columnIndex)); 504 columnValue = cursor [all...] |
/frameworks/base/core/java/android/app/ |
H A D | Activity.java | 734 ManagedCursor(Cursor cursor) { argument 735 mCursor = cursor; 1059 * where the cursor should be requeried (because you had deactivated it in 1733 * <p><strong>Warning:</strong> Do not call {@link Cursor#close()} on a cursor obtained using 1735 * you call {@link #stopManagingCursor} on a cursor from a managed query, the system <em>will 1736 * not</em> automatically close the cursor and, in that case, you must call 1773 * <p><strong>Warning:</strong> Do not call {@link Cursor#close()} on a cursor obtained using 1775 * you call {@link #stopManagingCursor} on a cursor from a managed query, the system <em>will 1776 * not</em> automatically close the cursor and, in that case, you must call 1814 * <p><strong>Warning:</strong> Do not call {@link Cursor#close()} on cursor obtaine [all...] |
H A D | AlertDialog.java | 651 * @param cursor The {@link Cursor} to supply the list of items 653 * @param labelColumn The column name on the cursor containing the string to display 658 public Builder setCursor(final Cursor cursor, final OnClickListener listener, argument 660 P.mCursor = cursor; 726 * @param cursor the cursor used to provide the items. 727 * @param isCheckedColumn specifies the column name on the cursor to use to determine 730 * @param labelColumn The column name on the cursor containing the string to display in the 738 public Builder setMultiChoiceItems(Cursor cursor, String isCheckedColumn, String labelColumn, argument 740 P.mCursor = cursor; 788 setSingleChoiceItems(Cursor cursor, int checkedItem, String labelColumn, final OnClickListener listener) argument [all...] |
H A D | DownloadManager.java | 329 /* add the following 'computed' columns to the cursor. 1028 Cursor cursor = null; 1030 cursor = query(query); 1031 if (cursor == null) { 1034 if (cursor.moveToFirst()) { 1035 int status = cursor.getInt(cursor.getColumnIndexOrThrow(COLUMN_STATUS)); 1037 int indx = cursor.getColumnIndexOrThrow( 1039 int destination = cursor.getInt(indx); 1051 String path = cursor 1295 CursorTranslator(Cursor cursor, Uri baseUri) argument [all...] |
/frameworks/base/core/java/android/content/ |
H A D | AsyncQueryHandler.java | 77 Cursor cursor; 79 cursor = resolver.query(args.uri, args.projection, 82 // Calling getCount() causes the cursor window to be filled, 84 if (cursor != null) { 85 cursor.getCount(); 89 cursor = null; 92 args.result = cursor; 284 * @param cursor The cursor holding the results from the query. 286 protected void onQueryComplete(int token, Object cookie, Cursor cursor) { argument [all...] |
H A D | ContentProviderNative.java | 112 Cursor cursor = query(callingPkg, url, projection, selection, selectionArgs, 114 if (cursor != null) { 117 cursor, observer, getProviderName()); 119 cursor = null; 125 // Close cursor if an exception was thrown while constructing the adaptor. 126 if (cursor != null) { 127 cursor.close();
|
H A D | ContentProviderOperation.java | 237 final Cursor cursor = provider.query(mUri, projection, mSelection, selectionArgs, null); 239 numRows = cursor.getCount(); 241 while (cursor.moveToNext()) { 243 final String cursorValue = cursor.getString(i); 256 cursor.close();
|
H A D | ContentQueryMap.java | 28 * Caches the contents of a cursor into a Map of String->ContentValues and optionally 29 * keeps the cache fresh by registering for updates on the content backing the cursor. The column of 33 * The cursor data is accessed by row key and column name via getValue(). 47 /** Set when a cursor change notification is received and is cleared on a call to requery(). */ 51 * Creates a ContentQueryMap that caches the content backing the cursor 53 * @param cursor the cursor whose contents should be cached 55 * @param keepUpdated true if the cursor's ContentProvider should be monitored for changes and 62 public ContentQueryMap(Cursor cursor, String columnNameOfKey, boolean keepUpdated, argument 64 mCursor = cursor; 148 readCursorIntoCache(Cursor cursor) argument [all...] |
H A D | ContentResolver.java | 175 public static final String CURSOR_ITEM_BASE_TYPE = "vnd.android.cursor.item"; 191 * in the cursor is the same. 193 public static final String CURSOR_DIR_BASE_TYPE = "vnd.android.cursor.dir"; 484 // Wrap the cursor object into CursorWrapperInner object. 2252 CursorWrapperInner(Cursor cursor, IContentProvider icp) { argument 2253 super(cursor);
|
H A D | CursorEntityIterator.java | 23 * Abstract implementation of EntityIterator that makes it easy to wrap a cursor 32 * Constructor that makes initializes the cursor such that the iterator points to the 34 * @param cursor the cursor that contains the rows that make up the entities 36 public CursorEntityIterator(Cursor cursor) { argument 38 mCursor = cursor; 43 * Returns the entity that the cursor is currently pointing to. This must take care to advance 44 * the cursor past this entity. This will never be called if the cursor is at the end. 45 * @param cursor th 49 getEntityAndIncrementCursor(Cursor cursor) argument [all...] |
H A D | CursorLoader.java | 32 * querying cursors, building on {@link AsyncTaskLoader} to perform the cursor 65 Cursor cursor = getContext().getContentResolver().query(mUri, mProjection, mSelection, 67 if (cursor != null) { 69 // Ensure the cursor window is filled. 70 cursor.getCount(); 71 cursor.registerContentObserver(mObserver); 73 cursor.close(); 77 return cursor; 98 public void deliverResult(Cursor cursor) { argument 101 if (cursor ! 172 onCanceled(Cursor cursor) argument [all...] |
/frameworks/base/core/java/android/database/ |
H A D | AbstractCursor.java | 31 * This is an abstract cursor class that handles a lot of the common code 56 * the column at {@link #mRowIdColumnIndex} for the current row this cursor is 98 // TODO implement getBlob in all cursor types 106 * If the cursor is backed by a {@link CursorWindow}, returns a pre-filled 107 * window with the contents of the cursor, otherwise null. 109 * @return The pre-filled window that backs this cursor, or null if none. 152 * This function is called every time the cursor is successfully scrolled 155 * cursor will scroll to the beforeFirst position. 196 // Make sure position isn't past the end of the cursor 203 // Make sure position isn't before the beginning of the cursor 446 SelfContentObserver(AbstractCursor cursor) argument [all...] |
H A D | BulkCursorDescriptor.java | 44 public IBulkCursor cursor; field in class:BulkCursorDescriptor 57 out.writeStrongBinder(cursor.asBinder()); 70 cursor = BulkCursorNative.asInterface(in.readStrongBinder());
|
H A D | BulkCursorToCursorAdaptor.java | 42 mBulkCursor = d.cursor; 64 throw new StaleDataException("Attempted to access a cursor after it has been closed.");
|
H A D | CrossProcessCursorWrapper.java | 27 * If the wrapped cursor implements {@link CrossProcessCursor}, then the wrapper 30 * traverse the contents of the cursor similar to {@link AbstractCursor#fillWindow}. 38 * Creates a cross process cursor wrapper. 39 * @param cursor The underlying cursor to wrap. 41 public CrossProcessCursorWrapper(Cursor cursor) { argument 42 super(cursor);
|
H A D | CursorJoiner.java | 59 /** The row currently pointed to by the left cursor is unique */ 61 /** The row currently pointed to by the right cursor is unique */ 70 * @param cursorLeft The left cursor to compare 71 * @param columnNamesLeft The column names to compare from the left cursor 72 * @param cursorRight The right cursor to compare 73 * @param columnNamesRight The column names to compare from the right cursor 104 * @param cursor the cursor that contains the columns 108 private int[] buildColumnIndiciesArray(Cursor cursor, String[] columnNames) { argument 111 columns[i] = cursor 204 populateValues(String[] values, Cursor cursor, int[] columnIndicies, int startingIndex) argument [all...] |
H A D | CursorToBulkCursorAdaptor.java | 29 * If the wrapped cursor returns non-null from {@link CrossProcessCursor#getWindow} 46 * The cursor that is being adapted. 47 * This field is set to null when the cursor is closed. 52 * The cursor window that was filled by the cross process cursor in the 53 * case where the cursor does not support getWindow. 91 public CursorToBulkCursorAdaptor(Cursor cursor, IContentObserver observer, argument 93 if (cursor instanceof CrossProcessCursor) { 94 mCursor = (CrossProcessCursor)cursor; 96 mCursor = new CrossProcessCursorWrapper(cursor); [all...] |
H A D | CursorWrapper.java | 24 * Wrapper class for Cursor that delegates all calls to the actual cursor object. The primary 25 * use for this class is to extend a cursor while overriding only a subset of its methods. 32 * Creates a cursor wrapper. 33 * @param cursor The underlying cursor to wrap. 35 public CursorWrapper(Cursor cursor) { argument 36 mCursor = cursor; 40 * Gets the underlying cursor that is wrapped by this instance. 42 * @return The wrapped cursor.
|
H A D | DatabaseUtils.java | 253 * Fills the specified cursor window by iterating over the contents of the cursor. 254 * The window is filled until the cursor is exhausted or the window runs out 257 * The original position of the cursor is left unchanged by this operation. 259 * @param cursor The cursor that contains the data to put in the window. 264 public static void cursorFillWindow(final Cursor cursor, argument 266 if (position < 0 || position >= cursor.getCount()) { 269 final int oldPos = cursor.getPosition(); 270 final int numColumns = cursor 448 dumpCursor(Cursor cursor) argument 459 dumpCursor(Cursor cursor, PrintStream stream) argument 480 dumpCursor(Cursor cursor, StringBuilder sb) argument 501 dumpCursorToString(Cursor cursor) argument 512 dumpCurrentRow(Cursor cursor) argument 522 dumpCurrentRow(Cursor cursor, PrintStream stream) argument 546 dumpCurrentRow(Cursor cursor, StringBuilder sb) argument 570 dumpCurrentRowToString(Cursor cursor) argument 583 cursorStringToContentValues(Cursor cursor, String field, ContentValues values) argument 596 cursorStringToInsertHelper(Cursor cursor, String field, InsertHelper inserter, int index) argument 609 cursorStringToContentValues(Cursor cursor, String field, ContentValues values, String key) argument 621 cursorIntToContentValues(Cursor cursor, String field, ContentValues values) argument 633 cursorIntToContentValues(Cursor cursor, String field, ContentValues values, String key) argument 650 cursorLongToContentValues(Cursor cursor, String field, ContentValues values) argument 663 cursorLongToContentValues(Cursor cursor, String field, ContentValues values, String key) argument 681 cursorDoubleToCursorValues(Cursor cursor, String field, ContentValues values) argument 694 cursorDoubleToContentValues(Cursor cursor, String field, ContentValues values, String key) argument 710 cursorRowToContentValues(Cursor cursor, ContentValues values) argument 886 cursorStringToContentValuesIfPresent(Cursor cursor, ContentValues values, String column) argument 902 cursorLongToContentValuesIfPresent(Cursor cursor, ContentValues values, String column) argument 918 cursorShortToContentValuesIfPresent(Cursor cursor, ContentValues values, String column) argument 934 cursorIntToContentValuesIfPresent(Cursor cursor, ContentValues values, String column) argument 950 cursorFloatToContentValuesIfPresent(Cursor cursor, ContentValues values, String column) argument 966 cursorDoubleToContentValuesIfPresent(Cursor cursor, ContentValues values, String column) argument [all...] |
/frameworks/base/core/java/android/database/sqlite/ |
H A D | SQLiteCursorDriver.java | 44 void cursorRequeried(Cursor cursor); argument
|
H A D | SQLiteDirectCursorDriver.java | 24 * A cursor driver that uses the given query directly. 45 final Cursor cursor; 50 cursor = new SQLiteCursor(this, mEditTable, query); 52 cursor = factory.newCursor(mDatabase, this, mEditTable, query); 60 return cursor; 75 public void cursorRequeried(Cursor cursor) { argument
|
H A D | SqliteWrapper.java | 67 public static boolean requery(Context context, Cursor cursor) { argument 69 return cursor.requery();
|
/frameworks/base/core/java/android/provider/ |
H A D | Browser.java | 229 * Return a cursor pointing to a list of all the bookmarks. The cursor will have a single 244 * Return a cursor pointing to a list of all visited site urls. The cursor will 398 Cursor cursor = null; 402 cursor = cr.query(History.CONTENT_URI, 406 if (cursor.moveToFirst() && cursor.getCount() >= MAX_HISTORY_COUNT) { 410 cr.delete(ContentUris.withAppendedId(History.CONTENT_URI, cursor.getLong(0)), 412 iconDb.releaseIconForPageUrl(cursor [all...] |
H A D | BrowserContract.java | 330 public static final String CONTENT_TYPE = "vnd.android.cursor.dir/bookmark"; 335 public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/bookmark"; 452 public static final String CONTENT_TYPE = "vnd.android.cursor.dir/browser-history"; 457 public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/browser-history"; 475 public static final String CONTENT_TYPE = "vnd.android.cursor.dir/searches"; 480 public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/searches"; 581 public static final String CONTENT_TYPE = "vnd.android.cursor.dir/images"; 586 public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/images"; 654 public static final String CONTENT_TYPE = "vnd.android.cursor.dir/image_mappings"; 659 public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor [all...] |
H A D | CalendarContract.java | 114 * <data android:mimeType="vnd.android.cursor.item/event" /> 502 * Creates an entity iterator for the given cursor. It assumes the 503 * cursor contains a calendars query. 505 * @param cursor query on {@link #CONTENT_URI} 508 public static EntityIterator newEntityIterator(Cursor cursor) { argument 509 return new EntityIteratorImpl(cursor); 514 public EntityIteratorImpl(Cursor cursor) { argument 515 super(cursor); 519 public Entity getEntityAndIncrementCursor(Cursor cursor) throws RemoteException { argument 520 // we expect the cursor i 1292 newEntityIterator(Cursor cursor, ContentResolver resolver) argument 1304 newEntityIterator(Cursor cursor, ContentProviderClient provider) argument 1348 EntityIteratorImpl(Cursor cursor, ContentResolver resolver) argument 1354 EntityIteratorImpl(Cursor cursor, ContentProviderClient provider) argument 1361 getEntityAndIncrementCursor(Cursor cursor) argument [all...] |