/packages/apps/Dialer/java/com/android/dialer/common/database/ |
D | Selection.java | 70 private final String selection; field in Selection 73 private Selection(@NonNull String selection, @NonNull String[] selectionArgs) { in Selection() argument 74 this.selection = selection; in Selection() 80 return selection; in getSelection() 89 return selection.isEmpty(); in isEmpty() 113 public static Selection fromString(@Nullable String selection, @Nullable String... args) { in fromString() argument 114 return new Builder(selection, args == null ? Collections.emptyList() : Arrays.asList(args)) in fromString() 119 public static Selection fromString(@Nullable String selection, Collection<String> args) { in fromString() argument 120 return new Builder(selection, args).build(); in fromString() 125 public static Selection not(@NonNull Selection selection) { in not() argument [all …]
|
/packages/apps/DocumentsUI/tests/unit/com/android/documentsui/dirlist/ |
D | DragStartListenerTest.java | 26 import androidx.recyclerview.selection.MutableSelection; 27 import androidx.recyclerview.selection.Selection; 91 (Selection<String> selection) -> { in setUp() 129 Selection<String> selection = mListener.getSelectionToBeCopied("1234", in testDragStart_nonSelectedItem() local 131 assertTrue(selection.size() == 1); in testDragStart_nonSelectedItem() 132 assertTrue(selection.contains("1234")); in testDragStart_nonSelectedItem() 137 MutableSelection<String> selection = new MutableSelection<>(); in testDragStart_selectedItem() local 138 selection.add("1234"); in testDragStart_selectedItem() 139 selection.add("5678"); in testDragStart_selectedItem() 140 mSelectionMgr.replaceSelection(selection); in testDragStart_selectedItem() [all …]
|
/packages/providers/TelephonyProvider/src/com/android/providers/telephony/ |
D | MmsSmsProvider.java | 343 String selection, String[] selectionArgs, String sortOrder) { in query() argument 356 SqlQueryChecker.checkQueryParametersForSubqueries(projection, selection, sortOrder); in query() 368 cursor = getCompleteConversations(projection, selection, sortOrder, smsTable, in query() 376 selection = concatSelections( in query() 377 selection, Threads.TYPE + "=" + threadType); in query() 380 projection, selection, selectionArgs, sortOrder); in query() 383 projection, selection, sortOrder, smsTable, pduTable); in query() 388 selection, sortOrder, smsTable, pduTable); in query() 392 uri.getPathSegments().get(1), projection, selection, in query() 397 uri.getPathSegments().get(1), projection, selection, in query() [all …]
|
D | CarrierProvider.java | 61 public Cursor query(Uri uri, String[] projectionIn, String selection, in query() argument 67 + " selection=" + selection in query() 74 Cursor c = qb.query(db, projectionIn, selection, selectionArgs, null, null, sortOrder); in query() 92 public int delete(Uri uri, String selection, String[] selectionArgs) { in delete() argument 96 + " selection={" + selection + "}" in delete() 97 + " selection=" + selection in delete() 101 selection, selectionArgs); in delete() 107 public int update(Uri uri, ContentValues values, String selection, String[] selectionArgs) { in update() argument 113 + " selection=" + selection in update() 117 values, selection, selectionArgs); in update()
|
/packages/apps/Calendar/src/com/android/calendar/alerts/ |
D | DismissAlarmsService.java | 74 String selection; in onHandleIntent() local 79 selection = CalendarAlerts.STATE + "=" + CalendarAlerts.STATE_FIRED + " AND " + in onHandleIntent() 83 selection = buildMultipleEventsQuery(eventIds); in onHandleIntent() 89 selection = CalendarAlerts.STATE + "=" + CalendarAlerts.STATE_FIRED; in onHandleIntent() 97 resolver.update(uri, values, selection, null); in onHandleIntent() 117 StringBuilder selection = new StringBuilder(); in buildMultipleEventsQuery() local 118 selection.append(CalendarAlerts.STATE); in buildMultipleEventsQuery() 119 selection.append("="); in buildMultipleEventsQuery() 120 selection.append(CalendarAlerts.STATE_FIRED); in buildMultipleEventsQuery() 122 selection.append(" AND ("); in buildMultipleEventsQuery() [all …]
|
/packages/apps/Contacts/tests/src/com/android/contacts/test/mocks/ |
D | MockContentProvider.java | 95 public Query withSelection(String selection, String... selectionArgs) { in withSelection() argument 96 mSelection = selection; in withSelection() 136 public boolean equals(Uri uri, String[] projection, String selection, in equals() argument 150 if (!mAnySelection && !Objects.equals(selection, mSelection)) { in equals() 329 public Delete withSelection(String selection, @Nullable String[] selectionArgs) { in withSelection() argument 330 mSelection = Preconditions.checkNotNull(selection); in withSelection() 368 private boolean equals(Uri uri, String selection, String[] selectionArgs) { in equals() argument 369 return mUri.equals(uri) && Objects.equals(mSelection, selection) in equals() 393 @Nullable String selection, in Update() argument 397 mSelection = selection; in Update() [all …]
|
/packages/apps/DocumentsUI/src/com/android/documentsui/files/ |
D | ActionHandler.java | 38 import androidx.recyclerview.selection.ItemDetailsLookup.ItemDetails; 39 import androidx.recyclerview.selection.MutableSelection; 40 import androidx.recyclerview.selection.Selection; 144 Selection<String> selection = getStableSelection(); in openSelectedInNewWindow() local 145 assert(selection.size() == 1); in openSelectedInNewWindow() 146 DocumentInfo doc = mModel.getDocument(selection.iterator().next()); in openSelectedInNewWindow() 230 final MutableSelection<String> selection = this.getStableSelection(); in getSelectedOrFocused() local 231 if (selection.isEmpty()) { in getSelectedOrFocused() 234 selection.add(focusModelId); in getSelectedOrFocused() 238 return selection; in getSelectedOrFocused() [all …]
|
/packages/apps/Gallery2/src/com/android/photos/data/ |
D | PhotoProvider.java | 272 public int deleteInTransaction(Uri uri, String selection, String[] selectionArgs, in deleteInTransaction() argument 275 selection = addIdToSelection(match, selection); in deleteInTransaction() 277 return deleteCascade(uri, match, selection, selectionArgs); in deleteInTransaction() 308 public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, in query() argument 310 return query(uri, projection, selection, selectionArgs, sortOrder, null); in query() 314 public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, in query() argument 318 selection = addIdToSelection(match, selection); in query() 321 … Cursor c = query(table, projection, selection, selectionArgs, sortOrder, cancellationSignal); in query() 329 public int updateInTransaction(Uri uri, ContentValues values, String selection, in updateInTransaction() argument 337 selection = addIdToSelection(match, selection); in updateInTransaction() [all …]
|
/packages/providers/CalendarProvider/src/com/android/providers/calendar/ |
D | CalendarProvider2.java | 852 public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, in query() argument 862 return queryInternal(uri, projection, selection, selectionArgs, sortOrder); in query() 926 private String appendPrimaryOnlyToSelection(String selection) { in appendPrimaryOnlyToSelection() argument 927 return TextUtils.isEmpty(selection) in appendPrimaryOnlyToSelection() 929 : selection + " AND (" + SELECTION_PRIMARY_CALENDAR + ")"; in appendPrimaryOnlyToSelection() 939 String selection, String[] selectionArgs, String sortOrder, in queryWorkProfileProvider() argument 959 selection = appendPrimaryOnlyToSelection(selection); in queryWorkProfileProvider() 962 selection, selectionArgs, sortOrder); in queryWorkProfileProvider() 966 private Cursor queryInternal(Uri uri, String[] projection, String selection, in queryInternal() argument 985 return mDbHelper.getSyncState().query(db, projection, selection, selectionArgs, in queryInternal() [all …]
|
/packages/providers/BlockedNumberProvider/src/com/android/providers/blockednumber/ |
D | BlockedNumberProvider.java | 184 public int update(@NonNull Uri uri, @Nullable ContentValues values, @Nullable String selection, in update() argument 193 public int delete(@NonNull Uri uri, @Nullable String selection, in delete() argument 201 numRows = deleteBlockedNumber(selection, selectionArgs); in delete() 204 numRows = deleteBlockedNumberWithId(ContentUris.parseId(uri), selection); in delete() 217 private int deleteBlockedNumberWithId(long id, String selection) { in deleteBlockedNumberWithId() argument 218 throwForNonEmptySelection(selection); in deleteBlockedNumberWithId() 226 private int deleteBlockedNumber(String selection, String[] selectionArgs) { in deleteBlockedNumber() argument 230 if (!TextUtils.isEmpty(selection)) { in deleteBlockedNumber() 232 Utils.wrapSelectionWithParens(selection), in deleteBlockedNumber() 238 selection, selectionArgs); in deleteBlockedNumber() [all …]
|
/packages/apps/Dialer/java/com/android/dialer/blocking/ |
D | FilteredNumberProvider.java | 64 Uri uri, String[] projection, String selection, String[] selectionArgs, String sortOrder) { in query() argument 78 final Cursor c = qb.query(db, projection, selection, selectionArgs, null, null, null); in query() 123 public int delete(Uri uri, String selection, String[] selectionArgs) { in delete() argument 130 selection = getSelectionWithId(selection, ContentUris.parseId(uri)); in delete() 136 db.delete(DialerDatabaseHelper.Tables.FILTERED_NUMBER_TABLE, selection, selectionArgs); in delete() 144 public int update(Uri uri, ContentValues values, String selection, String[] selectionArgs) { in update() argument 151 selection = getSelectionWithId(selection, ContentUris.parseId(uri)); in update() 158 DialerDatabaseHelper.Tables.FILTERED_NUMBER_TABLE, values, selection, selectionArgs); in update() 165 private String getSelectionWithId(String selection, long id) { in getSelectionWithId() argument 166 if (TextUtils.isEmpty(selection)) { in getSelectionWithId() [all …]
|
/packages/providers/DownloadProvider/src/com/android/providers/downloads/ |
D | DownloadStorageProvider.java | 843 String selection, String[] selectionArgs, CancellationSignal signal) in queryForSingleItem() argument 846 ContentResolver.createSqlQueryBundle(selection, selectionArgs, null), signal); in queryForSingleItem() 939 final StringBuilder selection = new StringBuilder(); in buildSearchSelection() local 943 if (selection.length() > 0) { in buildSearchSelection() 944 selection.append(" AND "); in buildSearchSelection() 946 selection.append(DownloadColumns.DATA + " NOT IN ("); in buildSearchSelection() 947 selection.append(TextUtils.join(",", Collections.nCopies(filePaths.size(), "?"))); in buildSearchSelection() 948 selection.append(")"); in buildSearchSelection() 953 if (selection.length() > 0) { in buildSearchSelection() 954 selection.append(" AND "); in buildSearchSelection() [all …]
|
/packages/apps/SettingsIntelligence/src/com/android/settings/intelligence/search/query/ |
D | DatabaseResultTask.java | 175 final String[] selection = buildSingleWordSelection(query, matchColumns.length); in firstWordQuery() local 177 return query(whereClause, selection, baseRank); in firstWordQuery() 191 final String[] selection = buildSingleWordSelection(query, matchColumns.length); in secondaryWordQuery() local 193 return query(whereClause, selection, baseRank); in secondaryWordQuery() 206 final String[] selection = buildAnyWordSelection(matchColumns.length * 2); in anyWordQuery() local 208 return query(whereClause, selection, baseRank); in anyWordQuery() 219 private Set<SearchResult> query(String whereClause, String[] selection, int baseRank) { in query() argument 224 selection, null, null, null)) { in query() argument 277 String[] selection = new String[size]; in buildSingleWordSelection() local 280 selection[i] = query; in buildSingleWordSelection() [all …]
|
/packages/apps/Messaging/src/com/android/messaging/datamodel/ |
D | DatabaseWrapper.java | 198 final String[] projection, final String selection, in explainQueryPlan() argument 207 selection, in explainQueryPlan() 245 final String selection, final String[] selectionArgs, final String groupBy, in query() argument 250 explainQueryPlan(qb, mDatabase, projection, selection, selectionArgs, in query() 259 final Cursor cursor = mDatabase.query(searchTable, projection, selection, selectionArgs, in query() 265 searchTable, selection, cursor.getCount())); in query() 271 final String selection, final String[] selectionArgs, final String groupBy, in query() argument 274 searchTable, columns, selection, selectionArgs, in query() 279 final String[] projection, final String selection, final String[] queryArgs, in query() argument 282 explainQueryPlan(qb, mDatabase, projection, selection, queryArgs, in query() [all …]
|
/packages/apps/Dialer/java/com/android/dialer/calllog/database/ |
D | AnnotatedCallLogContentProvider.java | 88 @Nullable String selection, in query() argument 99 queryBuilder.query(db, projection, selection, selectionArgs, null, null, sortOrder); in query() 109 queryBuilder.query(db, projection, selection, selectionArgs, null, null, sortOrder); in query() 124 queryBuilder.query(db, projection, selection, selectionArgs, null, null, sortOrder); in query() 192 @NonNull Uri uri, @Nullable String selection, @Nullable String[] selectionArgs) { in delete() argument 199 Assert.checkArgument(selection == null, "Do not specify selection when deleting by ID"); in delete() 204 selection = getSelectionWithId(id); in delete() 211 int rows = database.delete(AnnotatedCallLog.TABLE, selection, selectionArgs); in delete() 226 @Nullable String selection, in update() argument 237 int rows = database.update(AnnotatedCallLog.TABLE, values, selection, selectionArgs); in update() [all …]
|
/packages/services/Car/tests/BugReportApp/src/com/google/android/car/bugreport/ |
D | BugStorageProvider.java | 223 @Nullable String selection, in query() argument 226 return query(uri, projection, selection, selectionArgs, sortOrder, null); in query() 234 @Nullable String selection, in query() argument 247 if (selection != null || selectionArgs != null) { in query() 251 selection = COLUMN_ID + "=?"; in query() 258 Cursor cursor = db.query(false, table, null, selection, selectionArgs, null, null, in query() 305 @NonNull Uri uri, @Nullable String selection, @Nullable String[] selectionArgs) { in delete() argument 309 if (selection != null || selectionArgs != null) { in delete() 319 if (selection != null || selectionArgs != null) { in delete() 323 selection = COLUMN_ID + " = ?"; in delete() [all …]
|
/packages/providers/ContactsProvider/src/com/android/providers/contacts/ |
D | ContactsProvider2.java | 2200 public int update(Uri uri, ContentValues values, String selection, String[] selectionArgs) { in update() argument 2204 mContactsHelper.validateSql(getCallingPackage(), selection); in update() local 2208 return mProfileProvider.update(uri, values, selection, selectionArgs); in update() 2211 return super.update(uri, values, selection, selectionArgs); in update() 2215 public int delete(Uri uri, String selection, String[] selectionArgs) { in delete() argument 2218 mContactsHelper.validateSql(getCallingPackage(), selection); in delete() local 2222 return mProfileProvider.delete(uri, selection, selectionArgs); in delete() 2225 return super.delete(uri, selection, selectionArgs); in delete() 2885 private Long findGroupByRawContactId(String selection, long rawContactId) { in findGroupByRawContactId() argument 2888 PROJECTION_GROUP_ID, selection, in findGroupByRawContactId() [all …]
|
D | ProfileProvider.java | 66 public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, in query() argument 68 return query(uri, projection, selection, selectionArgs, sortOrder, null); in query() 72 public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, in query() argument 77 return mDelegate.queryLocal(uri, projection, selection, selectionArgs, sortOrder, -1, in query() 91 protected int updateInTransaction(Uri uri, ContentValues values, String selection, in updateInTransaction() argument 94 return mDelegate.updateInTransaction(uri, values, selection, selectionArgs); in updateInTransaction() 98 protected int deleteInTransaction(Uri uri, String selection, String[] selectionArgs) { in deleteInTransaction() argument 100 return mDelegate.deleteInTransaction(uri, selection, selectionArgs); in deleteInTransaction()
|
D | CallLogProvider.java | 297 public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, in query() argument 304 return queryInternal(uri, projection, selection, selectionArgs, sortOrder); in query() 310 private Cursor queryInternal(Uri uri, String[] projection, String selection, in queryInternal() argument 314 " selection=[" + selection + "] args=" + Arrays.toString(selectionArgs) + in queryInternal() 327 final SelectionBuilder selectionBuilder = new SelectionBuilder(selection); in queryInternal() 455 public int update(Uri uri, ContentValues values, String selection, String[] selectionArgs) { in update() argument 461 return updateInternal(uri, values, selection, selectionArgs); in update() 468 public int delete(Uri uri, String selection, String[] selectionArgs) { in delete() argument 474 return deleteInternal(uri, selection, selectionArgs); in delete() 511 String selection, String[] selectionArgs) { in updateInternal() argument [all …]
|
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/category/ |
D | MainPanel.java | 53 private void selection(int position, boolean value) { in selection() method in MainPanel 155 selection(mCurrentSelected, false); in loadCategoryLookPanel() 160 selection(mCurrentSelected, true); in loadCategoryLookPanel() 168 selection(mCurrentSelected, false); in loadCategoryBorderPanel() 173 selection(mCurrentSelected, true); in loadCategoryBorderPanel() 184 selection(mCurrentSelected, false); in loadCategoryGeometryPanel() 189 selection(mCurrentSelected, true); in loadCategoryGeometryPanel() 197 selection(mCurrentSelected, false); in loadCategoryFiltersPanel() 202 selection(mCurrentSelected, true); in loadCategoryFiltersPanel() 212 selection(mCurrentSelected, false); in loadCategoryVersionsPanel() [all …]
|
/packages/apps/DocumentsUI/src/com/android/documentsui/dirlist/ |
D | DragStartListener.java | 27 import androidx.recyclerview.selection.MutableSelection; 28 import androidx.recyclerview.selection.Selection; 29 import androidx.recyclerview.selection.SelectionTracker; 122 Selection<String> selection = getSelectionToBeCopied(modelId, event); in startDrag() local 124 final List<DocumentInfo> srcs = mDocsConverter.apply(selection); in startDrag() 149 MutableSelection<String> selection = new MutableSelection<>(); in getSelectionToBeCopied() local 159 mSelectionMgr.copySelection(selection); in getSelectionToBeCopied() 161 selection.add(modelId); in getSelectionToBeCopied() 164 return selection; in getSelectionToBeCopied()
|
/packages/apps/DocumentsUI/src/com/android/documentsui/clipping/ |
D | RuntimeDocumentClipper.java | 30 import androidx.recyclerview.selection.Selection; 93 Function<String, Uri> uriBuilder, Selection<String> selection, @OpType int opType) { in getClipDataForDocuments() argument 95 assert(selection != null); in getClipDataForDocuments() 97 if (selection.isEmpty()) { in getClipDataForDocuments() 102 final List<Uri> uris = new ArrayList<>(selection.size()); in getClipDataForDocuments() 103 for (String id : selection) { in getClipDataForDocuments() 194 Function<String, Uri> uriBuilder, Selection<String> selection) { in clipDocumentsForCopy() argument 196 getClipDataForDocuments(uriBuilder, selection, FileOperationService.OPERATION_COPY); in clipDocumentsForCopy() 204 Function<String, Uri> uriBuilder, Selection<String> selection, DocumentInfo parent) { in clipDocumentsForCut() argument 205 assert(!selection.isEmpty()); in clipDocumentsForCut() [all …]
|
/packages/apps/DocumentsUI/src/com/android/documentsui/ |
D | MenuManager.java | 58 public void updateActionMenu(Menu menu, SelectionDetails selection) { in updateActionMenu() argument 59 updateOpenWith(menu.findItem(R.id.action_menu_open_with), selection); in updateActionMenu() local 60 updateDelete(menu.findItem(R.id.action_menu_delete), selection); in updateActionMenu() local 61 updateShare(menu.findItem(R.id.action_menu_share), selection); in updateActionMenu() local 62 updateRename(menu.findItem(R.id.action_menu_rename), selection); in updateActionMenu() local 63 updateSelect(menu.findItem(R.id.action_menu_select), selection); in updateActionMenu() local 65 updateMoveTo(menu.findItem(R.id.action_menu_move_to), selection); in updateActionMenu() local 66 updateCopyTo(menu.findItem(R.id.action_menu_copy_to), selection); in updateActionMenu() local 67 updateCompress(menu.findItem(R.id.action_menu_compress), selection); in updateActionMenu() local 68 updateExtractTo(menu.findItem(R.id.action_menu_extract_to), selection); in updateActionMenu() local [all …]
|
/packages/modules/CellBroadcastService/src/com/android/cellbroadcastservice/ |
D | CellBroadcastProvider.java | 176 public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, in query() argument 184 + " selection = " + selection in query() 203 CELL_BROADCASTS_TABLE_NAME, projection, selection, selectionArgs, in query() 208 return qb.query(getReadableDatabase(), projection, selection, selectionArgs, null, in query() 246 public int delete(Uri uri, String selection, String[] selectionArgs) { in delete() argument 252 + " selection = " + selection in delete() 259 selection, selectionArgs); in delete() 267 public int update(Uri uri, ContentValues values, String selection, String[] selectionArgs) { in update() argument 274 + " selection = " + selection in update() 283 selection, in update()
|
/packages/providers/TvProvider/src/com/android/providers/tv/util/ |
D | SqlParams.java | 26 public SqlParams(String tables, String selection, String... selectionArgs) { in SqlParams() argument 28 setWhere(selection, selectionArgs); in SqlParams() 47 public void setWhere(String selection, String... selectionArgs) { in setWhere() argument 48 mSelection = selection; in setWhere() 52 public void appendWhere(String selection, String... selectionArgs) { in appendWhere() argument 53 mSelection = DatabaseUtils.concatenateWhere(mSelection, selection); in appendWhere()
|