Searched defs:cursor (Results 1 - 25 of 85) sorted by relevance

1234

/frameworks/ex/common/java/com/android/common/io/
H A DMoreCloseables.java26 * Closes the supplied cursor iff it is not null.
28 public static void closeQuietly(Cursor cursor) { argument
29 if (cursor != null) {
30 cursor.close();
/frameworks/base/core/java/android/content/
H A DCursorEntityIterator.java23 * 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 DContentQueryMap.java28 * 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 DAsyncQueryHandler.java77 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...]
/frameworks/base/core/java/android/database/
H A DBulkCursorDescriptor.java44 public IBulkCursor cursor; field in class:BulkCursorDescriptor
57 out.writeStrongBinder(cursor.asBinder());
70 cursor = BulkCursorNative.asInterface(in.readStrongBinder());
H A DCrossProcessCursorWrapper.java27 * 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);
/frameworks/base/core/java/android/database/sqlite/
H A DSQLiteCursorDriver.java44 void cursorRequeried(Cursor cursor); argument
H A DSQLiteDirectCursorDriver.java24 * 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 DSqliteWrapper.java67 public static boolean requery(Context context, Cursor cursor) { argument
69 return cursor.requery();
/frameworks/base/core/java/android/text/util/
H A DRfc822Tokenizer.java51 int cursor = text.length();
53 while (i < cursor) {
59 while (i < cursor && text.charAt(i) == ' ') {
81 while (i < cursor) {
88 if (i + 1 < cursor) {
101 while (i < cursor && level > 0) {
116 if (i + 1 < cursor) {
128 while (i < cursor) {
210 public int findTokenStart(CharSequence text, int cursor) { argument
213 * we reach the cursor
241 findTokenEnd(CharSequence text, int cursor) argument
[all...]
/frameworks/base/core/tests/coretests/src/android/database/
H A DMatrixCursorTest.java28 Cursor cursor = new MatrixCursor(new String[] { "a" });
29 assertEquals(0, cursor.getCount());
33 MatrixCursor cursor = new MatrixCursor(new String[] { "a" });
34 cursor.newRow().add(null);
35 cursor.moveToNext();
36 assertTrue(cursor.isNull(0));
37 assertNull(cursor.getString(0));
38 assertNull(cursor.getBlob(0));
39 assertEquals(0, cursor.getShort(0));
40 assertEquals(0, cursor
200 checkValues(MatrixCursor cursor) argument
[all...]
/frameworks/base/tests/LocationTracker/src/com/android/locationtracker/data/
H A DTrackerListHelper.java50 Cursor cursor = mActivity.managedQuery(TrackerProvider.CONTENT_URI,
53 TrackerAdapter adapter = new TrackerAdapter(mActivity, layout, cursor);
55 cursor.setNotificationUri(mActivity.getContentResolver(),
67 public void bindView(View view, Context context, Cursor cursor) { argument
71 .createEntry(cursor));
H A DTrackerDataHelper.java111 Cursor cursor = mContext.getContentResolver().query(
114 if (cursor == null) {
115 return cursor;
117 int pos = (cursor.getCount() < limit ? 0 : cursor.getCount() - limit);
118 cursor.moveToPosition(pos);
119 return cursor;
123 * Retrieves a cursor that starts at the last limit rows
126 * @return a cursor, null if bad things happened
158 * Helper method which converts row referenced by given cursor t
165 getNextOutput(Cursor cursor) argument
[all...]
/frameworks/support/v17/leanback/src/android/support/v17/leanback/database/
H A DCursorMapper.java31 protected abstract void bindColumns(Cursor cursor); argument
38 protected abstract Object bind(Cursor cursor); argument
43 public Object convert(Cursor cursor) { argument
44 if (cursor != mCursor) {
45 mCursor = cursor;
/frameworks/base/core/java/android/widget/
H A DCursorFilter.java32 CharSequence convertToString(Cursor cursor); argument
35 void changeCursor(Cursor cursor); argument
49 Cursor cursor = mClient.runQueryOnBackgroundThread(constraint);
52 if (cursor != null) {
53 results.count = cursor.getCount();
54 results.values = cursor;
H A DResourceCursorAdapter.java68 * @param c The cursor from which to get the data.
70 * cursor whenever it changes so the most recent
86 * @param c The cursor from which to get the data.
103 public View newView(Context context, Cursor cursor, ViewGroup parent) { argument
108 public View newDropDownView(Context context, Cursor cursor, ViewGroup parent) { argument
H A DResourceCursorTreeAdapter.java41 * @param cursor The database cursor
51 public ResourceCursorTreeAdapter(Context context, Cursor cursor, int collapsedGroupLayout, argument
53 super(cursor, context);
68 * @param cursor The database cursor
76 public ResourceCursorTreeAdapter(Context context, Cursor cursor, int collapsedGroupLayout, argument
78 this(context, cursor, collapsedGroupLayout, expandedGroupLayout, childLayout, childLayout);
86 * @param cursor The database cursor
92 ResourceCursorTreeAdapter(Context context, Cursor cursor, int groupLayout, int childLayout) argument
98 newChildView(Context context, Cursor cursor, boolean isLastChild, ViewGroup parent) argument
104 newGroupView(Context context, Cursor cursor, boolean isExpanded, ViewGroup parent) argument
[all...]
H A DAlphabetIndexer.java28 * invalidates the cache if changes occur in the cursor.
30 * Your adapter is responsible for updating the cursor by calling {@link #setCursor} if the
31 * cursor changes. {@link #getPositionForSection} method does the binary search for the starting
42 * The index of the cursor column that this list is sorted on.
58 * the dataset changes or the cursor changes.
74 * @param cursor the cursor containing the data set
75 * @param sortedColumnIndex the column number in the cursor that is sorted
82 public AlphabetIndexer(Cursor cursor, int sortedColumnIndex, CharSequence alphabet) { argument
83 mDataCursor = cursor;
112 setCursor(Cursor cursor) argument
[all...]
/frameworks/support/v4/java/android/support/v4/widget/
H A DCursorFilter.java33 CharSequence convertToString(Cursor cursor); argument
36 void changeCursor(Cursor cursor); argument
50 Cursor cursor = mClient.runQueryOnBackgroundThread(constraint);
53 if (cursor != null) {
54 results.count = cursor.getCount();
55 results.values = cursor;
H A DResourceCursorAdapter.java70 * @param c The cursor from which to get the data.
72 * cursor whenever it changes so the most recent
88 * @param c The cursor from which to get the data.
105 public View newView(Context context, Cursor cursor, ViewGroup parent) { argument
110 public View newDropDownView(Context context, Cursor cursor, ViewGroup parent) { argument
/frameworks/base/core/tests/coretests/src/android/app/
H A DSuggestionProvider.java69 MatrixCursor cursor = new MatrixCursor(COLUMNS);
72 addRow(cursor, query + suffix);
74 return cursor;
80 private void addRow(MatrixCursor cursor, String string) { argument
81 long id = cursor.getCount();
82 cursor.newRow().add(id).add(string).add(Intent.ACTION_SEARCH).add(string);
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/
H A DFilteringCursorWrapper.java38 public FilteringCursorWrapper(Cursor cursor, String[] acceptMimes) { argument
39 this(cursor, acceptMimes, null, Long.MIN_VALUE);
42 public FilteringCursorWrapper(Cursor cursor, String[] acceptMimes, String[] rejectMimes) { argument
43 this(cursor, acceptMimes, rejectMimes, Long.MIN_VALUE);
47 Cursor cursor, String[] acceptMimes, String[] rejectMimes, long rejectBefore) {
48 mCursor = cursor;
50 final int count = cursor.getCount();
53 cursor.moveToPosition(-1);
54 while (cursor.moveToNext() && mCount < count) {
55 final String mimeType = getCursorString(cursor, Documen
46 FilteringCursorWrapper( Cursor cursor, String[] acceptMimes, String[] rejectMimes, long rejectBefore) argument
[all...]
/frameworks/base/telephony/java/android/telephony/
H A DPhoneNumberFormattingTextWatcher.java124 * Generate the formatted number by ignoring all non-dialable chars and stick the cursor to the
126 * removed then the cursor should be behind '3' instead of '-'.
128 private String reformat(CharSequence s, int cursor) { argument
129 // The index of char to the leftward of the cursor.
130 int curIndex = cursor - 1;
/frameworks/opt/telephony/src/java/com/google/android/mms/util/
H A DSqliteWrapper.java79 public static boolean requery(Context context, Cursor cursor) { argument
81 return cursor.requery();
/frameworks/support/v17/leanback/src/android/support/v17/leanback/widget/
H A DCursorObjectAdapter.java51 * Change the underlying cursor to a new cursor. If there is
52 * an existing cursor it will be closed if it is different than the new
53 * cursor.
55 * @param cursor The new cursor to be used.
57 public void changeCursor(Cursor cursor) { argument
58 if (cursor == mCursor) {
64 mCursor = cursor;
73 * @param cursor Th
75 swapCursor(Cursor cursor) argument
[all...]

Completed in 5202 milliseconds

1234