Home
last modified time | relevance | path

Searched refs:Pair (Results 1 – 25 of 749) sorted by relevance

12345678910>>...30

/frameworks/base/services/tests/servicestests/src/com/android/server/job/
DWorkTypeConfigTest.java33 import android.util.Pair;
69 @NonNull List<Pair<Integer, Float>> defaultMinRatios, in check()
70 @NonNull List<Pair<Integer, Float>> defaultMaxRatios, in check()
72 @NonNull List<Pair<Integer, Integer>> expectedMinLimits, in check()
73 @NonNull List<Pair<Integer, Integer>> expectedMaxLimits) throws Exception { in check()
97 for (Pair<Integer, Integer> min : expectedMinLimits) { in check()
101 for (Pair<Integer, Integer> max : expectedMaxLimits) { in check()
114 /* min */ List.of(Pair.create(WORK_TYPE_TOP, 1), Pair.create(WORK_TYPE_EJ, 0), in test()
115 Pair.create(WORK_TYPE_BG, 0), Pair.create(WORK_TYPE_BGUSER, 0)), in test()
116 /* max */ List.of(Pair.create(WORK_TYPE_TOP, 13), Pair.create(WORK_TYPE_EJ, 13), in test()
[all …]
DWorkCountTrackerTest.java34 import android.util.Pair;
182 @NonNull List<Pair<Integer, Float>> minLimitRatios, in recount()
183 @NonNull List<Pair<Integer, Float>> maxLimitRatios) { in recount()
250 @NonNull List<Pair<Integer, Float>> minLimitRatios, in checkRandom()
251 @NonNull List<Pair<Integer, Float>> maxLimitRatios, in checkRandom()
254 for (Pair<Integer, Float> minLimit : minLimitRatios) { in checkRandom()
275 for (Pair<Integer, Float> maxLimitRatio : maxLimitRatios) { in checkRandom()
295 final List<Pair<Integer, Float>> minLimitRatios = in testRandom1()
296 List.of(Pair.create(WORK_TYPE_BG, 1.0f / 3)); in testRandom1()
297 final List<Pair<Integer, Float>> maxLimitRatios = in testRandom1()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/theme/
DDynamicColors.kt19 import android.util.Pair
26 fun allDynamicColorsMapped(isExtendedFidelity: Boolean): List<Pair<String, DynamicColor>> { in allDynamicColorsMapped()
29 Pair.create("primary_container", mdc.primaryContainer()), in allDynamicColorsMapped()
30 Pair.create("on_primary_container", mdc.onPrimaryContainer()), in allDynamicColorsMapped()
31 Pair.create("primary", mdc.primary()), in allDynamicColorsMapped()
32 Pair.create("on_primary", mdc.onPrimary()), in allDynamicColorsMapped()
33 Pair.create("secondary_container", mdc.secondaryContainer()), in allDynamicColorsMapped()
34 Pair.create("on_secondary_container", mdc.onSecondaryContainer()), in allDynamicColorsMapped()
35 Pair.create("secondary", mdc.secondary()), in allDynamicColorsMapped()
36 Pair.create("on_secondary", mdc.onSecondary()), in allDynamicColorsMapped()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/bouncer/data/factory/
DBouncerMessageFactory.kt125 ): Pair<Int, Int>? { in getBouncerMessage()
190 private fun defaultMessage(securityMode: SecurityMode): Pair<Int, Int> { in emptyMessage()
192 SecurityMode.Pattern -> Pair(keyguard_enter_pattern, 0) in emptyMessage()
193 SecurityMode.Password -> Pair(keyguard_enter_password, 0) in emptyMessage()
194 SecurityMode.PIN -> Pair(keyguard_enter_pin, 0) in emptyMessage()
195 else -> Pair(0, 0) in emptyMessage()
199 private fun defaultMessageWithFingerprint(securityMode: SecurityMode): Pair<Int, Int> { in defaultMessageWithFingerprint()
201 SecurityMode.Pattern -> Pair(kg_unlock_with_pattern_or_fp, 0) in defaultMessageWithFingerprint()
202 SecurityMode.Password -> Pair(kg_unlock_with_password_or_fp, 0) in defaultMessageWithFingerprint()
203 SecurityMode.PIN -> Pair(kg_unlock_with_pin_or_fp, 0) in defaultMessageWithFingerprint()
[all …]
/frameworks/base/core/tests/coretests/src/android/graphics/
DFontTestUtil.java19 import android.util.Pair;
84 private static final List<Pair<Integer, Boolean>> sStyleList;
85 private static final Map<Pair<Integer, Boolean>, String> sFontMap;
86 private static final Map<Pair<Integer, Boolean>, Integer> sTtcMap;
87 private static final Map<Pair<Integer, Boolean>, String> sVariationSettingsMap;
132 ArrayList<Pair<Integer, Boolean>> styles = new ArrayList<>();
133 styles.add(new Pair<>(100, false)); in styles.add()
134 styles.add(new Pair<>(100, true)); in styles.add()
135 styles.add(new Pair<>(200, false)); in styles.add()
136 styles.add(new Pair<>(200, true)); in styles.add()
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/pipeline/wifi/shared/model/
DWifiNetworkModelTest.kt104 assertThat(logger.changes).contains(Pair(COL_NETWORK_TYPE, TYPE_INACTIVE)) in <lambda>()
105 assertThat(logger.changes).contains(Pair(COL_NETWORK_ID, NETWORK_ID_DEFAULT.toString())) in <lambda>()
106 assertThat(logger.changes).contains(Pair(COL_VALIDATED, "false")) in <lambda>()
107 assertThat(logger.changes).contains(Pair(COL_LEVEL, LEVEL_DEFAULT.toString())) in <lambda>()
108 assertThat(logger.changes).contains(Pair(COL_SSID, "null")) in <lambda>()
123 assertThat(logger.changes).contains(Pair(COL_NETWORK_TYPE, TYPE_CARRIER_MERGED)) in <lambda>()
124 assertThat(logger.changes).contains(Pair(COL_NETWORK_ID, "6")) in <lambda>()
125 assertThat(logger.changes).contains(Pair(COL_SUB_ID, "3")) in <lambda>()
126 assertThat(logger.changes).contains(Pair(COL_VALIDATED, "true")) in <lambda>()
127 assertThat(logger.changes).contains(Pair(COL_LEVEL, "2")) in <lambda>()
[all …]
/frameworks/base/packages/SettingsLib/IllustrationPreference/src/com/android/settingslib/widget/
DColorUtils.java24 import android.util.Pair;
43 private static HashMap<String, Pair<Integer, Integer>> sFixedColors;
46 sFixedColors.put(".blue600", new Pair<Integer, Integer>(
48 sFixedColors.put(".green600", new Pair<Integer, Integer>(
50 sFixedColors.put(".red600", new Pair<Integer, Integer>(
52 sFixedColors.put(".yellow600", new Pair<Integer, Integer>(
54 sFixedColors.put(".blue400", new Pair<Integer, Integer>(
56 sFixedColors.put(".green400", new Pair<Integer, Integer>(
58 sFixedColors.put(".red400", new Pair<Integer, Integer>(
60 sFixedColors.put(".yellow400", new Pair<Integer, Integer>(
[all …]
/frameworks/base/tests/NetworkSecurityConfigTest/src/android/security/net/config/
DNetworkSecurityConfigTests.java24 import android.util.Pair;
125 ArraySet<Pair<Domain, NetworkSecurityConfig>> domainMap in testEmptyConfig()
126 = new ArraySet<Pair<Domain, NetworkSecurityConfig>>(); in testEmptyConfig()
134 ArraySet<Pair<Domain, NetworkSecurityConfig>> domainMap in testEmptyPerNetworkSecurityConfig()
135 = new ArraySet<Pair<Domain, NetworkSecurityConfig>>(); in testEmptyPerNetworkSecurityConfig()
136 domainMap.add(new Pair<Domain, NetworkSecurityConfig>( in testEmptyPerNetworkSecurityConfig()
152 ArraySet<Pair<Domain, NetworkSecurityConfig>> domainMap in testBadPin()
153 = new ArraySet<Pair<Domain, NetworkSecurityConfig>>(); in testBadPin()
154 domainMap.add(new Pair<Domain, NetworkSecurityConfig>( in testBadPin()
170 ArraySet<Pair<Domain, NetworkSecurityConfig>> domainMap in testGoodPin()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/metrics/
DCallQualityMetrics.java25 import android.util.Pair;
62 private ArrayList<Pair<CallQuality, Integer>> mUlSnapshots = new ArrayList<>();
65 private ArrayList<Pair<CallQuality, Integer>> mDlSnapshots = new ArrayList<>();
83 private Pair<CallQuality, Integer> mWorstSsWithGoodDlQuality;
84 private Pair<CallQuality, Integer> mBestSsWithGoodDlQuality;
85 private Pair<CallQuality, Integer> mWorstSsWithBadDlQuality;
86 private Pair<CallQuality, Integer> mBestSsWithBadDlQuality;
87 private Pair<CallQuality, Integer> mWorstSsWithGoodUlQuality;
88 private Pair<CallQuality, Integer> mBestSsWithGoodUlQuality;
89 private Pair<CallQuality, Integer> mWorstSsWithBadUlQuality;
[all …]
/frameworks/base/libs/hwui/utils/
DPair.h26 struct Pair { struct
30 Pair() {} in Pair() argument
31 Pair(const Pair& o) : first(o.first), second(o.second) {} in Pair() function
32 Pair(const F& f, const S& s) : first(f), second(s) {} in Pair() argument
42 struct trait_trivial_ctor<uirenderer::Pair<F, S> > { argument
46 struct trait_trivial_dtor<uirenderer::Pair<F, S> > {
50 struct trait_trivial_copy<uirenderer::Pair<F, S> > {
54 struct trait_trivial_move<uirenderer::Pair<F, S> > {
/frameworks/base/services/tests/servicestests/src/com/android/server/locksettings/recoverablekeystore/
DTestOnlyInsecureCertificateHelperTest.java6 import android.util.Pair;
68 Map<String, Pair<SecretKey, byte[]>> rawKeys = new HashMap<>(); in testKeepOnlyWhitelistedInsecureKeys_emptyKeysList()
69 Map<String, Pair<SecretKey, byte[]>> expectedResult = new HashMap<>(); in testKeepOnlyWhitelistedInsecureKeys_emptyKeysList()
71 Map<String, Pair<SecretKey, byte[]>> filteredKeys = in testKeepOnlyWhitelistedInsecureKeys_emptyKeysList()
79 Map<String, Pair<SecretKey, byte[]>> rawKeys = new HashMap<>(); in testKeepOnlyWhitelistedInsecureKeys_singleNonWhitelistedKey()
80 Map<String, Pair<SecretKey, byte[]>> expectedResult = new HashMap<>(); in testKeepOnlyWhitelistedInsecureKeys_singleNonWhitelistedKey()
83 rawKeys.put(alias, Pair.create(TestData.generateKey(), /*metadata=*/ null)); in testKeepOnlyWhitelistedInsecureKeys_singleNonWhitelistedKey()
85 Map<String, Pair<SecretKey, byte[]>> filteredKeys = in testKeepOnlyWhitelistedInsecureKeys_singleNonWhitelistedKey()
93 Map<String, Pair<SecretKey, byte[]>> rawKeys = new HashMap<>(); in testKeepOnlyWhitelistedInsecureKeys_singleWhitelistedKey()
94 Map<String, Pair<SecretKey, byte[]>> expectedResult = new HashMap<>(); in testKeepOnlyWhitelistedInsecureKeys_singleWhitelistedKey()
[all …]
/frameworks/base/core/tests/coretests/src/android/view/
DRoundedCornersTest.java34 import android.util.Pair;
55 final Pair<Integer, Integer> radius = new Pair<>(10, 20); in testGetRoundedCorner()
81 equalTo(RoundedCorners.fromRadii(new Pair<>(10, 20), 200, 400).hashCode())); in testHashCode()
83 not(equalTo(RoundedCorners.fromRadii(new Pair<>(5, 10), 200, 400).hashCode()))); in testHashCode()
89 equalTo(RoundedCorners.fromRadii(new Pair<>(10, 20), 200, 400))); in testEquals()
92 not(equalTo(RoundedCorners.fromRadii(new Pair<>(5, 10), 200, 400)))); in testEquals()
138 final Pair<Integer, Integer> radius = new Pair<>(10, 20); in testRotateRoundedCorners_90()
154 final Pair<Integer, Integer> radius = new Pair<>(10, 20); in testRotateRoundedCorners_270()
170 final Pair<Integer, Integer> radius = new Pair<>(10, 20); in testFromRadius_cache()
178 final Pair<Integer, Integer> radius = new Pair<>(10, 20); in testFromRadius_wontCacheIfRadiusChanged()
[all …]
/frameworks/base/core/java/android/hardware/camera2/marshal/impl/
DMarshalQueryablePair.java22 import android.util.Pair;
34 implements MarshalQueryable<Pair<T1, T2>> {
36 private class MarshalerPair extends Marshaler<Pair<T1, T2>> {
37 private final Class<? super Pair<T1, T2>> mClass;
38 private final Constructor<Pair<T1, T2>> mConstructor;
45 protected MarshalerPair(TypeReference<Pair<T1, T2>> typeReference, in MarshalerPair()
83 mConstructor = (Constructor<Pair<T1, T2>>)mClass.getConstructor( in MarshalerPair()
91 public void marshal(Pair<T1, T2> value, ByteBuffer buffer) { in marshal()
103 public Pair<T1, T2> unmarshal(ByteBuffer buffer) { in unmarshal()
133 public int calculateMarshalSize(Pair<T1, T2> value) { in calculateMarshalSize()
[all …]
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/d2d/
DDtmfTransportConversionTest.java25 import android.util.Pair;
49 public Pair<String,String> messageAndValueDigits;
52 TestParams(Communicator.Message theMessage, Pair<String,String> theDigits, in TestParams()
105 new Pair<>("A", "A"), in generateTestCases()
111 new Pair<>("A", "B"), in generateTestCases()
117 new Pair<>("A", "C"), in generateTestCases()
124 new Pair<>("B", "A"), in generateTestCases()
130 new Pair<>("B", "B"), in generateTestCases()
136 new Pair<>("B", "C"), in generateTestCases()
143 new Pair<>("C", "A"), in generateTestCases()
[all …]
/frameworks/base/packages/SystemUI/monet/src/com/android/systemui/monet/
DColorScheme.kt47 fun getHueRotation(sourceHue: Float, hueAndRotations: List<Pair<Int, Int>>): Double { in <lambda>()
86 Pair(0, 18),
87 Pair(41, 15),
88 Pair(61, 10),
89 Pair(101, 12),
90 Pair(131, 15),
91 Pair(181, 18),
92 Pair(251, 15),
93 Pair(301, 12),
94 Pair(360, 12)
[all …]
/frameworks/base/core/java/android/util/
DPair.java28 public class Pair<F, S> { class
38 public Pair(F first, S second) { in Pair() method in Pair
53 if (!(o instanceof Pair)) { in equals()
56 Pair<?, ?> p = (Pair<?, ?>) o; in equals()
81 public static <A, B> Pair <A, B> create(A a, B b) { in create()
82 return new Pair<A, B>(a, b); in create()
/frameworks/ex/camera2/extensions/sample/src/java/androidx/camera/extensions/impl/
DBokehImageCaptureExtenderImpl.java30 import android.util.Pair;
132 Map<Integer, Pair<Image, TotalCaptureResult>> results, in getCaptureProcessor()
135 Pair<Image, TotalCaptureResult> result = results.get(DEFAULT_STAGE_ID); in getCaptureProcessor()
178 public void process(Map<Integer, Pair<Image, TotalCaptureResult>> results, in getCaptureProcessor()
180 Pair<Image, TotalCaptureResult> result = results.get(DEFAULT_STAGE_ID); in getCaptureProcessor()
183 ArrayList<Pair<CaptureResult.Key, Object>> captureResults = in getCaptureProcessor()
191 captureResults.add(new Pair<>(CaptureResult.CONTROL_AE_MODE, in getCaptureProcessor()
198 captureResults.add(new Pair<>( in getCaptureProcessor()
205 captureResults.add(new Pair<>(CaptureResult.CONTROL_AE_LOCK, in getCaptureProcessor()
212 captureResults.add(new Pair<>(CaptureResult.CONTROL_AE_STATE, in getCaptureProcessor()
[all …]
DHdrImageCaptureExtenderImpl.java30 import android.util.Pair;
141 Map<Integer, Pair<Image, TotalCaptureResult>> results, in getCaptureProcessor()
155 public void process(Map<Integer, Pair<Image, TotalCaptureResult>> results, in getCaptureProcessor()
157 Pair<Image, TotalCaptureResult> result = results.get(NORMAL_STAGE_ID); in getCaptureProcessor()
160 ArrayList<Pair<CaptureResult.Key, Object>> captureResults = in getCaptureProcessor()
168 captureResults.add(new Pair<>(CaptureResult.CONTROL_ZOOM_RATIO, in getCaptureProcessor()
174 captureResults.add(new Pair<>(CaptureResult.CONTROL_AF_MODE, in getCaptureProcessor()
180 captureResults.add(new Pair<>(CaptureResult.CONTROL_AF_TRIGGER, in getCaptureProcessor()
186 captureResults.add(new Pair<>(CaptureResult.CONTROL_AF_STATE, in getCaptureProcessor()
192 captureResults.add(new Pair<>(CaptureResult.CONTROL_AF_REGIONS, in getCaptureProcessor()
[all …]
/frameworks/base/services/tests/displayservicetests/src/com/android/server/display/utils/
DDeviceConfigParsingUtilsTest.java25 import android.util.Pair;
50 private final BiFunction<String, String, Pair<String, String>> mDataPointToPair = Pair::create;
51 private final Function<List<Pair<String, String>>, List<Pair<String, String>>>
72 List.of(Pair.create("key1", "value1"))))}, in parseDeviceConfigMapData()
75 List.of(Pair.create("key1", "value1"))))}, in parseDeviceConfigMapData()
78 List.of(Pair.create("key1", "value1"), Pair.create("key2", "value2"))))}, in parseDeviceConfigMapData()
85 Map<String, Map<String, List<Pair<String, String>>>> expectedMap) { in testParseDeviceConfigMap()
86 Map<String, Map<String, List<Pair<String, String>>>> result = in testParseDeviceConfigMap()
95 Map<String, Map<String, List<Pair<String, String>>>> result = in testDataPointMapperReturnsNull()
104 Map<String, Map<String, List<Pair<String, String>>>> result = in testDataSetMapperReturnsNull()
/frameworks/base/services/core/java/com/android/server/hdmi/
DHdmiLogger.java21 import android.util.Pair;
52 private final HashMap<String, Pair<Long, Integer>> mWarningTimingCache = new HashMap<>();
54 private final HashMap<String, Pair<Long, Integer>> mErrorTimingCache = new HashMap<>();
112 private static String updateLog(HashMap<String, Pair<Long, Integer>> cache, String logMessage) { in updateLog()
114 Pair<Long, Integer> timing = cache.get(logMessage); in updateLog()
117 cache.put(logMessage, new Pair<>(curTime, 1)); in updateLog()
125 private static String buildMessage(String message, @Nullable Pair<Long, Integer> timing) { in buildMessage()
131 private static void increaseLogCount(HashMap<String, Pair<Long, Integer>> cache, in increaseLogCount()
133 Pair<Long, Integer> timing = cache.get(message); in increaseLogCount()
135 cache.put(message, new Pair<>(timing.first, timing.second + 1)); in increaseLogCount()
[all …]
/frameworks/av/media/img_utils/include/img_utils/
DPair.h29 class ANDROID_API Pair {
34 Pair() {} in Pair() function
36 Pair(const Pair& o) : first(o.first), second(o.second) {} in Pair() function
38 Pair(const F& f, const S& s) : first(f), second(s) {} in Pair() function
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/bouncer/data/repo/
DBouncerMessageRepositoryTest.kt230 Pair(keyguard_enter_pin, R.string.kg_prompt_after_update_pin), in <lambda>()
253 Pair(keyguard_enter_pin, kg_prompt_after_dpm_lock), in <lambda>()
270 Pair(keyguard_enter_pin, kg_prompt_reason_restart_pin), in <lambda>()
272 Pair(keyguard_enter_pin, kg_prompt_pin_auth_timeout), in <lambda>()
274 Pair(keyguard_enter_pin, kg_prompt_after_dpm_lock), in <lambda>()
276 Pair(keyguard_enter_pin, kg_trust_agent_disabled), in <lambda>()
278 Pair(keyguard_enter_pin, kg_trust_agent_disabled), in <lambda>()
280 Pair(keyguard_enter_pin, kg_prompt_after_user_lockdown_pin), in <lambda>()
282 Pair(keyguard_enter_pin, kg_prompt_unattended_update), in <lambda>()
284 Pair(keyguard_enter_pin, kg_prompt_auth_timeout), in <lambda>()
[all …]
/frameworks/opt/telephony/tests/telephonytests/src/android/telephony/ims/
DImsConfigImplTest.java26 import android.util.Pair;
46 public Pair<Integer, Integer> latestIntConfig;
47 public Pair<Integer, String> latestStringConfig;
57 latestIntConfig = new Pair<>(item, value); in setConfig()
63 latestStringConfig = new Pair<>(item, value); in setConfig()
115 final LinkedBlockingQueue<Pair<Integer, Integer>> mConfigChanges = in testIntCaching()
121 mConfigChanges.offer(new Pair<>(item, value)); in testIntCaching()
129 Pair<Integer, Integer> callbackResult = mConfigChanges.poll(); in testIntCaching()
144 final LinkedBlockingQueue<Pair<Integer, String>> mConfigChanges = in testStringCaching()
152 mConfigChanges.offer(new Pair<>(item, value)); in testStringCaching()
[all …]
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/
DBluetoothLeBroadcastMetadataExt.kt77 val entries = mutableListOf<Pair<String, String>>() in <lambda>()
78 entries.add(Pair(KEY_BT_QR_VER, QR_CODE_VER.toString())) in <lambda>()
79 entries.add(Pair(KEY_BT_ADDRESS_TYPE, this.sourceAddressType.toString())) in <lambda>()
80 entries.add(Pair(KEY_BT_DEVICE, this.sourceDevice.address.replace(":", "-"))) in <lambda>()
81 entries.add(Pair(KEY_BT_ADVERTISING_SID, this.sourceAdvertisingSid.toString())) in <lambda>()
82 entries.add(Pair(KEY_BT_BROADCAST_ID, this.broadcastId.toString())) in <lambda>()
84 entries.add(Pair(KEY_BT_BROADCAST_NAME, Base64.encodeToString( in <lambda>()
88 entries.add(Pair(KEY_BT_PUBLIC_BROADCAST_DATA, Base64.encodeToString( in <lambda>()
91 entries.add(Pair(KEY_BT_SYNC_INTERVAL, this.paSyncInterval.toString())) in <lambda>()
93 entries.add(Pair(KEY_BT_BROADCAST_CODE, in <lambda>()
[all …]
/frameworks/base/core/java/android/content/pm/
DConstrainDisplayApisConfig.java23 import android.util.Pair;
73 private ArrayMap<String, Pair<Long, Long>> mNeverConstrainConfigMap;
80 private ArrayMap<String, Pair<Long, Long>> mAlwaysConstrainConfigMap;
146 private static ArrayMap<String, Pair<Long, Long>> buildConfigMap(String configStr) { in buildConfigMap()
147 ArrayMap<String, Pair<Long, Long>> configMap = new ArrayMap<>(); in buildConfigMap()
170 Pair<Long, Long> minMaxVersionCodes = new Pair<>(minVersion, maxVersion); in buildConfigMap()
187 private static boolean flagHasMatchingPackageEntry(Map<String, Pair<Long, Long>> configMap, in flagHasMatchingPackageEntry()
207 private static boolean matchesApplicationInfo(Pair<Long, Long> minMaxVersionCodes, in matchesApplicationInfo()

12345678910>>...30