/packages/apps/DocumentsUI/tests/functional/com/android/documentsui/inspector/ |
D | DocumentLoaderTest.java | 102 LatchedConsumer<DocumentInfo> consumer = new LatchedConsumer<>(1); in testLoadsDocument() local 103 mLoader.loadDocInfo(validUri, mUserId, consumer); in testLoadsDocument() 108 consumer.assertCalled(1000, TimeUnit.MILLISECONDS); in testLoadsDocument() 110 assertNotNull(consumer.getValue()); in testLoadsDocument() 111 assertEquals(consumer.getValue().displayName, TEST_DOC_NAME); in testLoadsDocument() 112 assertEquals(consumer.getValue().size, 0); in testLoadsDocument() 121 LatchedConsumer<DocumentInfo> consumer = new LatchedConsumer<>(1); in testInvalidInput() local 122 mLoader.loadDocInfo(invalidUri, mUserId, consumer); in testInvalidInput() 127 consumer.assertCalled(1000, TimeUnit.MILLISECONDS); in testInvalidInput() 128 assertNull(consumer.getValue()); in testInvalidInput() [all …]
|
/packages/apps/QuickSearchBox/src/com/android/quicksearchbox/util/ |
D | Consumers.kt | 24 fun <A : QuietlyCloseable?> consumeCloseable(consumer: Consumer<A>?, value: A?) { in consumeCloseable() 27 accepted = consumer!!.consume(value!!) in consumeCloseable() 34 fun <A> consumeAsync(handler: Handler?, consumer: Consumer<A?>?, value: A?) { in consumeAsync() 36 consumer?.consume(value) in consumeAsync() 41 consumer?.consume(value) in consumeAsync() 51 consumer: Consumer<A>?, in consumeCloseableAsync() 55 consumeCloseable(consumer, value) in consumeCloseableAsync() 60 consumeCloseable(consumer, value) in consumeCloseableAsync() 67 fun <A> createAsyncConsumer(handler: Handler?, consumer: Consumer<A?>?): Consumer<A?> { in createAsyncConsumer() 70 consumeAsync(handler, consumer, value) in createAsyncConsumer() [all …]
|
D | CachedLater.kt | 52 for (consumer in waitingConsumers!!) { in create() method 53 if (DBG) Log.d(TAG, "Calling consumer: $consumer") in create() 54 consumer.consume(value) in create() 65 override fun getLater(consumer: Consumer<in A>?) { in getLater() 76 mWaitingConsumers?.add(consumer!!) in getLater() 81 consumer!!.consume(value!!) in getLater()
|
D | Now.kt | 21 override fun getLater(consumer: Consumer<in C?>?) { in getLater() 22 consumer!!.consume(now) in getLater()
|
D | SQLiteAsyncQuery.kt | 36 fun run(db: SQLiteDatabase?, consumer: Consumer<A>) { in performQuery() 38 consumer.consume(result) in performQuery()
|
D | NowOrLaterWrapper.kt | 21 override fun getLater(consumer: Consumer<in B>?) { in getLater() 25 return consumer!!.consume(get(value)) in getLater()
|
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/users/ |
D | RestrictedProfilePinDialogFragment.java | 109 public void setPin(String pin, String originalPin, Consumer<Boolean> consumer) { in setPin() argument 113 mUiThreadHandler.post(() -> consumer.accept(true)); in setPin() 118 public void deletePin(String oldPin, Consumer<Boolean> consumer) { in deletePin() argument 122 mUiThreadHandler.post(() -> consumer.accept(true)); in deletePin() 127 public void isPinCorrect(String pin, Consumer<Boolean> consumer) { in isPinCorrect() argument 131 mUiThreadHandler.post(() -> consumer.accept(isPinCorrect)); in isPinCorrect() 136 public void isPinSet(Consumer<Boolean> consumer) { in isPinSet() argument 140 mUiThreadHandler.post(() -> consumer.accept(isPinSet)); in isPinSet()
|
/packages/apps/QuickSearchBox/tests/src/com/android/quicksearchbox/ |
D | IconLoaderTest.java | 50 AssertConsumer<Object> consumer = new AssertConsumer<Object>(); in assertNull() local 51 value.getLater(consumer); in assertNull() 52 consumer.assertNull(); in assertNull() 60 AssertConsumer<Object> consumer = new AssertConsumer<Object>(); in assertNotNull() local 61 value.getLater(consumer); in assertNotNull() 62 consumer.assertNotNull(); in assertNotNull()
|
/packages/apps/Launcher3/quickstep/tests/multivalentTests/src/com/android/quickstep/util/ |
D | SplitSelectStateControllerTest.kt | 123 val consumer = in activeTasks_noMatchingTasks() constant 135 consumer.accept(tasks) in activeTasks_noMatchingTasks() 176 val consumer = in activeTasks_singleMatchingTask() constant 188 consumer.accept(tasks) in activeTasks_singleMatchingTask() 217 val consumer = in activeTasks_skipTaskWithDifferentUser() constant 229 consumer.accept(tasks) in activeTasks_skipTaskWithDifferentUser() 273 val consumer = in activeTasks_findTaskAsNonPrimaryUser() constant 285 consumer.accept(tasks) in activeTasks_findTaskAsNonPrimaryUser() 326 val consumer = in activeTasks_multipleMatchMostRecentTask() constant 338 consumer.accept(tasks) in activeTasks_multipleMatchMostRecentTask() [all …]
|
/packages/apps/Gallery2/src/com/android/gallery3d/data/ |
D | MediaSet.java | 187 public void enumerateMediaItems(ItemConsumer consumer) { in enumerateMediaItems() argument 188 enumerateMediaItems(consumer, 0); in enumerateMediaItems() 191 public void enumerateTotalMediaItems(ItemConsumer consumer) { in enumerateTotalMediaItems() argument 192 enumerateTotalMediaItems(consumer, 0); in enumerateTotalMediaItems() 202 protected int enumerateMediaItems(ItemConsumer consumer, int startIndex) { in enumerateMediaItems() argument 210 consumer.consume(startIndex + start + i, item); in enumerateMediaItems() 220 ItemConsumer consumer, int startIndex) { in enumerateTotalMediaItems() argument 222 start += enumerateMediaItems(consumer, startIndex); in enumerateTotalMediaItems() 226 consumer, startIndex + start); in enumerateTotalMediaItems()
|
D | ClusterAlbum.java | 83 ItemConsumer consumer = new ItemConsumer() { in getMediaItemFromPath() local 89 dataManager.mapMediaItems(subset, consumer, 0); in getMediaItemFromPath() 98 protected int enumerateMediaItems(ItemConsumer consumer, int startIndex) { in enumerateMediaItems() argument 99 mDataManager.mapMediaItems(mPaths, consumer, startIndex); in enumerateMediaItems() 128 ItemConsumer consumer = new ItemConsumer() { in delete() local 136 mDataManager.mapMediaItems(mPaths, consumer, 0); in delete()
|
D | LocalSource.java | 192 public void mapMediaItems(ArrayList<PathId> list, ItemConsumer consumer) { in mapMediaItems() argument 208 processMapMediaItems(imageList, consumer, true); in mapMediaItems() 209 processMapMediaItems(videoList, consumer, false); in mapMediaItems() 213 ItemConsumer consumer, boolean isImage) { in processMapMediaItems() argument 239 consumer.consume(pid2.id, items[k - i]); in processMapMediaItems()
|
/packages/services/Telephony/tests/src/com/android/services/telephony/rcs/ |
D | SipDelegateControllerTest.java | 102 BiConsumer<ISipDelegate, Set<FeatureTagState>> consumer = in testCreateDelegate() local 104 assertNotNull(consumer); in testCreateDelegate() 107 consumer.accept(mMockSipDelegate, Collections.emptySet()); in testCreateDelegate() 128 BiConsumer<ISipDelegate, Set<FeatureTagState>> consumer = in testCreateDeniedFeatures() local 130 assertNotNull(consumer); in testCreateDeniedFeatures() 136 consumer.accept(mMockSipDelegate, deniedTags); in testCreateDeniedFeatures() 244 BiConsumer<ISipDelegate, Set<FeatureTagState>> consumer = in testChangeSupportedFeatures() local 246 assertNotNull(consumer); in testChangeSupportedFeatures() 247 consumer.accept(mMockSipDelegate, Collections.emptySet()); in testChangeSupportedFeatures() 264 BiConsumer<ISipDelegate, Set<FeatureTagState>> consumer = in createSipDelegate() local [all …]
|
/packages/apps/Settings/src/com/android/settings/notification/modes/ |
D | FutureUtil.java | 32 static <V> void whenDone(ListenableFuture<V> future, Consumer<V> consumer, Executor executor) { in whenDone() argument 33 whenDone(future, consumer, executor, "Error in future"); in whenDone() 36 static <V> void whenDone(ListenableFuture<V> future, Consumer<V> consumer, Executor executor, in whenDone() argument 41 consumer.accept(v); in whenDone()
|
/packages/apps/Settings/src/com/android/settings/fuelgauge/batterytip/detectors/ |
D | HighUsageDetector.java | 89 for (UidBatteryConsumer consumer : uidBatteryConsumers) { in detect() 92 consumer.getConsumedPower(), totalPower, dischargeAmount); in detect() 94 || mBatteryUtils.shouldHideUidBatteryConsumer(consumer)) { in detect() 101 .setUid(consumer.getUid()) in detect() 102 .setPackageName(mBatteryUtils.getPackageName(consumer.getUid())) in detect()
|
/packages/apps/QuickSearchBox/src/com/android/quicksearchbox/ |
D | QueryTask.kt | 31 consumer: Consumer<C>? 65 consumer: Consumer<C>? in startQuery() 67 val task = QueryTask(query, maxResults, provider, handler, consumer) in startQuery() 84 mConsumer = consumer
|
/packages/modules/Telephony/services/QualifiedNetworksService/src/com/android/telephony/qns/ |
D | QnsTelephonyListener.java | 1199 for (Consumer<Integer> consumer : mSrvccStateConsumerList) { in onSrvccStateChanged() 1200 consumer.accept(state); in onSrvccStateChanged() 1206 for (Consumer<List<CallState>> consumer : mCallStatesConsumerList) { in onCallStatesChanged() 1207 consumer.accept(callStateList); in onCallStatesChanged() 1216 for (Consumer<MediaQualityStatus> consumer : mMediaQualityConsumerList) { in onMediaQualityStatusChanged() 1217 consumer.accept(status); in onMediaQualityStatusChanged() 1229 void addCallStatesChangedCallback(Consumer<List<CallState>> consumer) { in addCallStatesChangedCallback() argument 1230 mCallStatesConsumerList.add(consumer); in addCallStatesChangedCallback() 1233 void removeCallStatesChangedCallback(Consumer<List<CallState>> consumer) { in removeCallStatesChangedCallback() argument 1234 mCallStatesConsumerList.remove(consumer); in removeCallStatesChangedCallback() [all …]
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/systeminterface/ |
D | SystemPowerControlHelperTest.java | 67 private void testHelperMockedFileWrite(IntSupplier consumer, String target) throws Exception { in testHelperMockedFileWrite() argument 73 assertThat(consumer.getAsInt()).isEqualTo(SUSPEND_RESULT_SUCCESS); in testHelperMockedFileWrite() 134 private void testHelperMockedFileRead(BooleanSupplier consumer, String fileContents, in testHelperMockedFileRead() argument 147 consumer.getAsBoolean()).isEqualTo(result); in testHelperMockedFileRead()
|
/packages/apps/Launcher3/quickstep/src/com/android/quickstep/util/ |
D | CachedEventDispatcher.java | 51 public void setConsumer(Consumer<MotionEvent> consumer) { in setConsumer() argument 52 if (consumer == null) { in setConsumer() 55 mConsumer = consumer; in setConsumer()
|
/packages/apps/Car/VoiceControl/src/com/android/car/voicecontrol/ |
D | TextToSpeech.java | 81 default QuestionCallback createBooleanQuestionCallback(Consumer<Boolean> consumer, in createBooleanQuestionCallback() argument 96 consumer.accept(defaultAnswer); in createBooleanQuestionCallback() 99 consumer.accept(type == AnswerType.AFFIRMATIVE); in createBooleanQuestionCallback()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/batteryusage/ |
D | BatteryEntryTest.java | 99 UidBatteryConsumer consumer = mock(UidBatteryConsumer.class); in createBatteryEntryForApp() local 100 when(consumer.getUid()).thenReturn(APP_UID); in createBatteryEntryForApp() 101 when(consumer.getPackageWithHighestDrain()).thenReturn(highDrainPackage); in createBatteryEntryForApp() 103 mMockContext, mMockUserManager, consumer, false, APP_UID, packages, packageName); in createBatteryEntryForApp() 124 UserBatteryConsumer consumer = mock(UserBatteryConsumer.class); in createUserBatteryConsumer() local 125 when(consumer.getUserId()).thenReturn(userId); in createUserBatteryConsumer() 126 return new BatteryEntry(mMockContext, mMockUserManager, consumer, false, 0, null, null); in createUserBatteryConsumer()
|
/packages/modules/StatsD/statsd/src/socket/ |
D | LogEventFilter.h | 86 virtual void setAtomIds(AtomIdSet tagIds, ConsumerId consumer) { in setAtomIds() argument 90 mTagIdsPerConsumer.erase(consumer); in setAtomIds() 92 mTagIdsPerConsumer[consumer].swap(tagIds); in setAtomIds()
|
/packages/services/Telephony/src/com/android/phone/settings/ |
D | PickSmsSubscriptionActivity.java | 65 public static void addPendingResult(IIntegerConsumer consumer) { in addPendingResult() argument 67 sSmsPickPendingList.add(consumer); in addPendingResult() 69 Log.i(LOG_TAG, "queue pending result, token: " + consumer); in addPendingResult()
|
/packages/apps/Settings/src/com/android/settings/fuelgauge/ |
D | BatteryUtils.java | 205 public boolean shouldHideUidBatteryConsumer(UidBatteryConsumer consumer) { in shouldHideUidBatteryConsumer() argument 207 consumer, mPackageManager.getPackagesForUid(consumer.getUid())); in shouldHideUidBatteryConsumer() 214 public boolean shouldHideUidBatteryConsumer(UidBatteryConsumer consumer, String[] packages) { in shouldHideUidBatteryConsumer() argument 215 return mPowerUsageFeatureProvider.isTypeSystem(consumer.getUid(), packages) in shouldHideUidBatteryConsumer() 216 || shouldHideUidBatteryConsumerUnconditionally(consumer, packages); in shouldHideUidBatteryConsumer() 224 UidBatteryConsumer consumer, String[] packages) { in shouldHideUidBatteryConsumerUnconditionally() argument 225 final int uid = consumer.getUid(); in shouldHideUidBatteryConsumerUnconditionally()
|
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/task/ |
D | MockTask.java | 41 Consumer<AbstractProvisioningTask> consumer) { in MockTask() argument 43 mConsumer = requireNonNull(consumer); in MockTask()
|