Searched defs:cursor (Results 1 - 25 of 77) 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...]
/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
150 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/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...]
H A DMultiAutoCompleteTextView.java215 * <code>cursor</code> within <code>text</code>.
217 public int findTokenStart(CharSequence text, int cursor); argument
221 * that begins at offset <code>cursor</code> within <code>text</code>.
223 public int findTokenEnd(CharSequence text, int cursor); argument
237 public int findTokenStart(CharSequence text, int cursor) { argument
238 int i = cursor;
243 while (i < cursor && text.charAt(i) == ' ') {
250 public int findTokenEnd(CharSequence text, int cursor) { argument
251 int i = cursor;
/frameworks/ex/photoviewer/src/com/android/ex/photo/adapters/
H A DPhotoPagerAdapter.java42 public Fragment getItem(Context context, Cursor cursor, int position) { argument
43 final String photoUri = cursor.getString(mContentUriIndex);
44 final String thumbnailUri = cursor.getString(mThumbnailUriIndex);
71 public String getPhotoUri(Cursor cursor) { argument
72 return cursor.getString(mContentUriIndex);
/frameworks/opt/photoviewer/src/com/android/ex/photo/adapters/
H A DPhotoPagerAdapter.java44 public Fragment getItem(Context context, Cursor cursor, int position) { argument
45 final String photoUri = cursor.getString(mContentUriIndex);
46 final String thumbnailUri = cursor.getString(mThumbnailUriIndex);
49 loading = Boolean.valueOf(cursor.getString(mLoadingIndex));
87 public String getPhotoUri(Cursor cursor) { argument
88 return cursor.getString(mContentUriIndex);
/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/telephony/java/android/telephony/
H A DPhoneNumberFormattingTextWatcher.java125 * Generate the formatted number by ignoring all non-dialable chars and stick the cursor to the
127 * removed then the cursor should be behind '3' instead of '-'.
129 private String reformat(CharSequence s, int cursor) { argument
130 // The index of char to the leftward of the cursor.
131 int curIndex = cursor - 1;
/frameworks/opt/mms/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/opt/photoviewer/src/com/android/ex/photo/
H A DPhotoViewCallbacks.java45 * Called when the cursor that contains the photo list data
46 * is updated. Note that there is no guarantee that the cursor
48 * @param cursor the cursor containing the photo list data
50 public void onCursorChanged(Cursor cursor); argument

Completed in 1062 milliseconds

1234