Home
last modified time | relevance | path

Searched refs:supplier (Results 1 – 25 of 30) sorted by relevance

12

/frameworks/base/services/tests/uiservicestests/src/com/android/server/slice/
DPackageMatchingCacheTest.java42 private final Supplier<String> supplier = mock(Supplier.class); field in PackageMatchingCacheTest
43 private final PackageMatchingCache cache = new PackageMatchingCache(supplier);
49 verify(supplier, never()).get(); in testNulls()
53 verify(supplier).get(); in testNulls()
58 when(supplier.get()).thenReturn("ret.pkg"); in testCaching()
64 verify(supplier, times(1)).get(); in testCaching()
69 when(supplier.get()).thenReturn("ret.pkg"); in testGetOnFailure()
72 when(supplier.get()).thenReturn("other.pkg"); in testGetOnFailure()
74 verify(supplier, times(2)).get(); in testGetOnFailure()
/frameworks/base/services/core/java/com/android/server/
DSerialService.java104 final Supplier<ParcelFileDescriptor> supplier = mSerialPorts.get(path); in openSerialPort() local
105 if (supplier != null) { in openSerialPort()
106 return supplier.get(); in openSerialPort()
116 @NonNull Supplier<ParcelFileDescriptor> supplier) {
122 mSerialPorts.put(name, supplier);
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/
DExtensionControllerImpl.java119 Supplier<T> supplier) { in withUiMode() argument
120 mExtension.addUiMode(uiMode, supplier); in withUiMode()
126 Supplier<T> supplier) { in withFeature() argument
127 mExtension.addFeature(feature, supplier); in withFeature()
308 public UiModeItem(int uiMode, Supplier<T> supplier) { in UiModeItem() argument
310 mSupplier = supplier; in UiModeItem()
346 public FeatureItem(String feature, Supplier<T> supplier) { in FeatureItem() argument
347 mSupplier = supplier; in FeatureItem()
371 public Default(Supplier<T> supplier) { in Default() argument
372 mSupplier = supplier; in Default()
/frameworks/base/apct-tests/perftests/utils/src/android/perftests/utils/
DTestUtils.java38 public static <T> T getOnMainSync(@NonNull Supplier<T> supplier) { in getOnMainSync() argument
41 instrumentation.runOnMainSync(() -> result.set(supplier.get())); in getOnMainSync()
/frameworks/base/services/core/java/com/android/server/location/contexthub/
DContextHubClientBroker.java669 Supplier<Intent> supplier = in sendMessageToClient() local
674 return sendPendingIntent(supplier, nanoAppId, in sendMessageToClient()
724 Supplier<Intent> supplier = in onNanoAppAborted() local
727 sendPendingIntent(supplier, nanoAppId); in onNanoAppAborted()
931 Supplier<Intent> supplier = in sendAuthStateCallback() local
934 sendPendingIntent(supplier, nanoAppId); in sendAuthStateCallback()
995 private synchronized byte sendPendingIntent(Supplier<Intent> supplier) { in sendPendingIntent() argument
997 return doSendPendingIntent(mPendingIntentRequest.getPendingIntent(), supplier.get(), in sendPendingIntent()
1011 private synchronized byte sendPendingIntent(Supplier<Intent> supplier, long nanoAppId) { in sendPendingIntent() argument
1012 return sendPendingIntent(supplier, nanoAppId, null); in sendPendingIntent()
[all …]
/frameworks/base/services/robotests/backup/src/com/android/server/backup/remote/
DRemoteCallTest.java252 private static <T> Future<T> runInWorkerThreadAsync(Callable<T> supplier) { in runInWorkerThreadAsync() argument
254 new Thread(() -> future.complete(uncheck(supplier)), "test-worker-thread").start(); in runInWorkerThreadAsync()
258 private static <T> T runInWorkerThread(Callable<T> supplier) throws Exception { in runInWorkerThread() argument
259 return runInWorkerThreadAsync(supplier).get(); in runInWorkerThread()
/frameworks/base/packages/SystemUI/src/com/android/systemui/
DDejankUtils.java207 public static <T> T whitelistIpcs(Supplier<T> supplier) { in whitelistIpcs() argument
214 val = supplier.get(); in whitelistIpcs()
222 return supplier.get(); in whitelistIpcs()
/frameworks/base/core/java/android/hardware/
DSerialManagerInternal.java32 @NonNull Supplier<ParcelFileDescriptor> supplier); in addVirtualSerialPortForTest() argument
/frameworks/base/core/java/com/android/internal/infra/
DAndroidFuture.java483 public static <T> AndroidFuture<T> supply(Supplier<T> supplier) { in supply() argument
484 return supplyAsync(supplier, DIRECT_EXECUTOR); in supply()
490 public static <T> AndroidFuture<T> supplyAsync(Supplier<T> supplier, Executor executor) { in supplyAsync() argument
491 return new SupplyAsync<>(supplier, executor); in supplyAsync()
497 SupplyAsync(Supplier<T> supplier, Executor executor) { in SupplyAsync() argument
498 mSupplier = supplier; in SupplyAsync()
/frameworks/base/ravenwood/junit-impl-src/android/platform/test/ravenwood/
DRavenwoodContext.java159 private static <T> Supplier<T> memoize(ThrowingSupplier<T> supplier) { in memoize() argument
164 return supplier.get(); in memoize()
/frameworks/base/core/tests/coretests/src/android/widget/
DRemoteViewsAdapterTest.java225 private <T> T getOnUiThread(Supplier<T> supplier) throws Throwable { in getOnUiThread() argument
226 return getOnHandler(mMainHandler, supplier); in getOnUiThread()
235 private static <T> T getOnHandler(Handler handler, Supplier<T> supplier) throws Throwable { in getOnHandler() argument
237 handler.post(() -> result.set(supplier.get())); in getOnHandler()
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/desktopmode/
DEnterDesktopTaskTransitionHandler.java73 Supplier<SurfaceControl.Transaction> supplier) { in EnterDesktopTaskTransitionHandler() argument
75 mTransactionSupplier = supplier; in EnterDesktopTaskTransitionHandler()
DExitDesktopTaskTransitionHandler.java76 Supplier<SurfaceControl.Transaction> supplier, in ExitDesktopTaskTransitionHandler() argument
79 mTransactionSupplier = supplier; in ExitDesktopTaskTransitionHandler()
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/
DVeiledResizeTaskPositioner.java76 Supplier<SurfaceControl.Transaction> supplier, Transitions transitions) { in VeiledResizeTaskPositioner() argument
81 mTransactionSupplier = supplier; in VeiledResizeTaskPositioner()
DFluidResizeTaskPositioner.java81 Supplier<SurfaceControl.Transaction> supplier) { in FluidResizeTaskPositioner() argument
87 mTransactionSupplier = supplier; in FluidResizeTaskPositioner()
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/bar/
DBubbleBarExpandedView.java330 void setLayerBoundsSupplier(@Nullable Supplier<Rect> supplier) { in setLayerBoundsSupplier() argument
331 mLayerBoundsSupplier = supplier; in setLayerBoundsSupplier()
/frameworks/base/core/java/android/view/inputmethod/
DRemoteInputConnectionImpl.java1435 @NonNull AndroidFuture untypedFuture, @NonNull Supplier<T> supplier) { in dispatchWithTracing() argument
1436 dispatchWithTracing(methodName, untypedFuture, supplier, null /* dumpProtoProvider */); in dispatchWithTracing()
1440 @NonNull AndroidFuture untypedFuture, @NonNull Supplier<T> supplier, in dispatchWithTracing() argument
1447 result = supplier.get(); in dispatchWithTracing()
/frameworks/base/core/tests/coretests/src/android/view/
DViewInputConnectionTest.java364 private <T> T getOnMainSync(@NonNull Supplier<T> supplier) throws Throwable { in getOnMainSync() argument
366 mActivityRule.runOnUiThread(() -> result.set(supplier.get())); in getOnMainSync()
/frameworks/base/services/robotests/backup/src/com/android/server/backup/transport/
DTransportConnectionTest.java535 private <T> T runInWorkerThread(Supplier<T> supplier) throws Exception { in runInWorkerThread() argument
537 mWorkerHandler.post(() -> future.complete(supplier.get())); in runInWorkerThread()
/frameworks/base/packages/SystemUI/src/com/android/systemui/controls/ui/
DControlViewHolder.kt258 supplier: Supplier<out Behavior>, in bindBehavior()
261 val newBehavior = supplier.get() in bindBehavior()
/frameworks/base/core/java/com/android/internal/jank/
DInteractionJankMonitor.java477 @Cuj.CujType int cuj, Supplier<RunningTracker> supplier) { in putTrackerIfNoCurrent() argument
483 RunningTracker tracker = supplier.get(); in putTrackerIfNoCurrent()
/frameworks/base/services/core/java/com/android/server/wm/
DWindowContainer.java4144 WindowContainer<?> supplier) { in overrideConfigurationPropagation() argument
4145 overrideConfigurationPropagation(receiver, supplier, null /* configurationMerger */); in overrideConfigurationPropagation()
4161 WindowContainer<?> supplier, @Nullable ConfigurationMerger configurationMerger) { in overrideConfigurationPropagation() argument
4169 : supplier.getConfiguration(); in overrideConfigurationPropagation()
4173 supplier.registerConfigurationChangeListener(listener); in overrideConfigurationPropagation()
4178 supplier.unregisterConfigurationChangeListener(listener); in overrideConfigurationPropagation()
/frameworks/base/core/java/android/app/
DResourcesManager.java1097 final ApkAssetsSupplier supplier = new ApkAssetsSupplier(); in createApkAssetsSupplierNotLocked() local
1102 supplier.load(apkKey); in createApkAssetsSupplierNotLocked()
1107 return supplier; in createApkAssetsSupplierNotLocked()
/frameworks/base/packages/SystemUI/src/com/android/systemui/recents/
DOverviewProxyService.java433 private <T> T verifyCallerAndClearCallingIdentity(String reason, Supplier<T> supplier) {
439 return supplier.get();
/frameworks/base/services/core/java/com/android/server/rollback/
DRollbackManagerServiceImpl.java311 private <U> U awaitResult(Supplier<U> supplier) { in awaitResult() argument
314 return CompletableFuture.supplyAsync(supplier, mExecutor).get(); in awaitResult()

12