/packages/modules/Bluetooth/framework/tests/unit/src/android/bluetooth/le/ |
D | ScanRecordTest.java | 71 final Predicate<byte[]> matcher = in testMatchesAnyField_Eddystone_Parser() local 77 .matchesAnyField(matcher); in testMatchesAnyField_Eddystone_Parser() 91 final BytesMatcher matcher = BytesMatcher.decode("⊆0016AAFE/00FFFFFF"); in testMatchesAnyField_Eddystone() local 92 assertMatchesAnyField(RECORD_URL, matcher); in testMatchesAnyField_Eddystone() 93 assertMatchesAnyField(RECORD_UUID, matcher); in testMatchesAnyField_Eddystone() 94 assertMatchesAnyField(RECORD_TLM, matcher); in testMatchesAnyField_Eddystone() 95 assertMatchesAnyField(RECORD_E2EE_EID, matcher); in testMatchesAnyField_Eddystone() 96 assertNotMatchesAnyField(RECORD_IBEACON, matcher); in testMatchesAnyField_Eddystone() 101 final BytesMatcher matcher = in testMatchesAnyField_Eddystone_ExceptE2eeEid() local 103 assertMatchesAnyField(RECORD_URL, matcher); in testMatchesAnyField_Eddystone_ExceptE2eeEid() [all …]
|
/packages/apps/Launcher3/tests/src/com/android/launcher3/tapl/ |
D | TaplUtilityTest.java | 29 .matcher("Play Store").matches()); in testMakeMultilinePattern() 31 .matcher("PlayStore").matches()); in testMakeMultilinePattern() 35 .matcher("Play\nStore").matches()); in testMakeMultilinePattern() 37 .matcher("Play Store").matches()); in testMakeMultilinePattern() 40 .matcher("PlayStore").matches()); in testMakeMultilinePattern() 43 .matcher("Play\nStore").matches()); in testMakeMultilinePattern() 45 .matcher("Play \n Store").matches()); in testMakeMultilinePattern() 49 .matcher("Play Store has 7 notifications").matches()); in testMakeMultilinePattern() 51 .matcher("Play Store!").matches()); in testMakeMultilinePattern() 54 .matcher("play store").matches()); in testMakeMultilinePattern() [all …]
|
/packages/services/Car/car_product/car_ui_portrait/test/hostsidetests/car/src/android/car/ui/test/ |
D | TaskInfo.java | 54 Matcher matcher = taskPattern.matcher(string); in getComponentName() local 55 if (matcher.find()) { in getComponentName() 56 return matcher.group(); in getComponentName() 63 Matcher matcher = taskPattern.matcher(string); in getVisibility() local 64 if (matcher.find()) { in getVisibility() 65 String result = matcher.group(); in getVisibility() 73 Matcher matcher = taskIdGroupPattern.matcher(string); in getTaskId() local 74 if (matcher.find()) { in getTaskId() 75 String idGroup = matcher.group(); in getTaskId() 77 Matcher idMather = taskIdGroupPattern.matcher(idGroup); in getTaskId() [all …]
|
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/util/bluetooth/ |
D | BluetoothNameUtils.java | 46 Matcher matcher = NAME_PATTERN.matcher(bluetoothName); in getSetupType() local 47 if (!matcher.matches()) { in getSetupType() 51 String typeStr = matcher.group(1); in getSetupType() 70 Matcher matcher = NAME_PATTERN.matcher(bluetoothName); in getColorConfiguration() local 71 if (!matcher.matches()) { in getColorConfiguration() 75 final String cs = matcher.group(3); in getColorConfiguration() 79 final Matcher cm = COLOR_PATTERN.matcher(cs); in getColorConfiguration() 98 Matcher matcher = NAME_PATTERN.matcher(name); in isValidName() local 99 return matcher.matches(); in isValidName()
|
/packages/modules/StatsD/statsd/src/matchers/ |
D | matcher_util.cpp | 131 static unique_ptr<LogEvent> getTransformedEvent(const FieldValueMatcher& matcher, in getTransformedEvent() argument 133 if (!matcher.has_replace_string()) { in getTransformedEvent() 137 unique_ptr<Regex> re = Regex::create(matcher.replace_string().regex()); in getTransformedEvent() 143 const string& replacement = matcher.replace_string().replacement(); in getTransformedEvent() 196 static vector<pair<int, int>> computeRanges(const FieldValueMatcher& matcher, in computeRanges() argument 200 std::tie(start, end) = getStartEndAtDepth(matcher.field(), start, end, depth, values); in computeRanges() 208 if (matcher.has_position()) { in computeRanges() 214 switch (matcher.position()) { in computeRanges() 257 if (matcher.value_matcher_case() == FieldValueMatcher::kMatchesTuple) { in computeRanges() 286 static MatchResult matchesSimple(const sp<UidMap>& uidMap, const FieldValueMatcher& matcher, in matchesSimple() argument [all …]
|
D | CombinationAtomMatchingTracker.cpp | 55 AtomMatcher_Combination matcher = allAtomMatchers[matcherIndex].combination(); in init() local 58 if (!matcher.has_operation()) { in init() 64 mLogicalOperation = matcher.operation(); in init() 66 if (mLogicalOperation == LogicalOperation::NOT && matcher.matcher_size() != 1) { in init() 72 for (const auto& child : matcher.matcher()) { in init() 123 const AtomMatcher& matcher, const unordered_map<int64_t, int>& atomMatchingTrackerMap) { in onConfigUpdated() argument 125 const AtomMatcher_Combination& combinationMatcher = matcher.combination(); in onConfigUpdated() 126 for (const int64_t child : combinationMatcher.matcher()) { in onConfigUpdated() 132 INVALID_CONFIG_REASON_MATCHER_CHILD_NOT_FOUND, matcher.id()); in onConfigUpdated()
|
/packages/providers/ContactsProvider/src/com/android/providers/contacts/aggregation/ |
D | ContactAggregator.java | 95 final ContactMatcher matcher = new ContactMatcher(); in aggregateContact() local 100 matcher.clear(); in aggregateContact() 102 contactId = pickBestMatchBasedOnExceptions(db, rawContactId, matcher); in aggregateContact() 109 contactId = pickBestMatchBasedOnData(db, rawContactId, candidates, matcher); in aggregateContact() 549 ContactMatcher matcher) { in pickBestMatchBasedOnExceptions() argument 584 matcher.keepIn(contactId); in pickBestMatchBasedOnExceptions() 586 matcher.keepOut(contactId); in pickBestMatchBasedOnExceptions() 594 return matcher.pickBestMatch(MatchScore.MAX_SCORE, true); in pickBestMatchBasedOnExceptions() 612 MatchCandidateList candidates, ContactMatcher matcher) { in pickBestMatchBasedOnData() argument 615 long bestMatch = updateMatchScoresBasedOnDataMatches(db, rawContactId, matcher); in pickBestMatchBasedOnData() [all …]
|
D | ContactAggregator2.java | 111 RawContactMatcher matcher = new RawContactMatcher(); in aggregateContact() local 120 matcher); in aggregateContact() 209 rawContactId, MatchCandidateList candidates, RawContactMatcher matcher) { in findRawContactMatchingCandidates() argument 210 updateMatchScores(db, rawContactId, candidates, matcher); in findRawContactMatchingCandidates() 212 matcher.pickBestMatches()); in findRawContactMatchingCandidates() 500 RawContactMatcher matcher) { in updateMatchScoresBasedOnExceptions() argument 539 matcher.keepIn(rId, contactId, accountId); in updateMatchScoresBasedOnExceptions() 541 matcher.keepOut(rId, contactId, accountId); in updateMatchScoresBasedOnExceptions() 554 RawContactMatcher matcher) { in updateMatchScoresBasedOnIdentityMatch() argument 568 matcher.matchIdentity(rId, contactId, accountId); in updateMatchScoresBasedOnIdentityMatch() [all …]
|
/packages/modules/StatsD/statsd/src/ |
D | FieldValue.cpp | 47 bool Field::matches(const Matcher& matcher) const { in matches() 48 if (mTag != matcher.mMatcher.getTag()) { in matches() 51 if ((mField & matcher.mMask) == matcher.mMatcher.getField()) { in matches() 55 if (matcher.hasAllPositionMatcher() && in matches() 56 (mField & (matcher.mMask & kClearAllPositionMatcherMask)) == matcher.mMatcher.getField()) { in matches() 74 void translateFieldMatcher(int tag, const FieldMatcher& matcher, int depth, int* pos, int* mask, in translateFieldMatcher() argument 81 pos[depth] = matcher.field(); in translateFieldMatcher() 84 if (matcher.has_position()) { in translateFieldMatcher() 89 switch (matcher.position()) { in translateFieldMatcher() 113 if (matcher.child_size() == 0) { in translateFieldMatcher() [all …]
|
/packages/modules/Bluetooth/system/blueberry/tests/gd/cert/ |
D | behavior.py | 55 def begin(self, matcher): argument 56 return PersistenceStage(self, matcher, self._reply_stage_factory) 91 def wait_until_invoked(self, matcher, times, timeout): argument 96 invoked_times = sum((matcher(i) for i in self._invoked_obj)) 105 def __init__(self, behavior, matcher, reply_stage_factory): argument 107 self._matcher = matcher 121 def init(self, behavior, matcher, persistence): argument 123 self._matcher = matcher 132 def __init__(self, matcher, persistence, fn): argument 133 self._matcher = matcher [all …]
|
/packages/modules/StatsD/statsd/tests/ |
D | LogEntryMatcher_test.cpp | 147 AtomMatcher matcher; in TEST() local 148 auto simpleMatcher = matcher.mutable_simple_atom_matcher(); in TEST() 172 AtomMatcher matcher; in TEST() local 173 auto simpleMatcher = matcher.mutable_simple_atom_matcher(); in TEST() 402 AtomMatcher matcher; in TEST() local 403 auto simpleMatcher = matcher.mutable_simple_atom_matcher(); in TEST() 440 AtomMatcher matcher; in TEST() local 441 SimpleAtomMatcher* simpleMatcher = matcher.mutable_simple_atom_matcher(); in TEST() 488 AtomMatcher matcher; in TEST() local 489 SimpleAtomMatcher* simpleMatcher = matcher.mutable_simple_atom_matcher(); in TEST() [all …]
|
/packages/apps/Dialer/java/com/android/voicemail/impl/ |
D | DialerVvmConfigManager.java | 42 final CarrierIdentifierMatcher matcher; field in DialerVvmConfigManager.ConfigEntry 45 ConfigEntry(CarrierIdentifierMatcher matcher, PersistableBundle config) { in ConfigEntry() argument 46 this.matcher = matcher; in ConfigEntry() 57 if (!(matcher.gid1().isPresent() && other.matcher.gid1().isPresent())) { in compareTo() 58 if (matcher.gid1().isPresent()) { in compareTo() 60 } else if (other.matcher.gid1().isPresent()) { in compareTo() 66 comparisonChain = comparisonChain.compare(matcher.gid1().get(), other.matcher.gid1().get()); in compareTo() 69 return comparisonChain.compare(matcher.mccMnc(), other.matcher.mccMnc()).result(); in compareTo() 117 if (configEntry.matcher.matches(carrierIdentifier)) { in getConfig()
|
/packages/modules/StatsD/statsd/tests/e2e/ |
D | StringReplace_e2e_test.cpp | 368 AtomMatcher matcher = CreateStartScheduledJobAtomMatcher(); in TEST() local 369 FieldValueMatcher* fvm = matcher.mutable_simple_atom_matcher()->add_field_value_matcher(); in TEST() 375 *config.add_atom_matcher() = matcher; in TEST() 376 matcher = CreateFinishScheduledJobAtomMatcher(); in TEST() 377 fvm = matcher.mutable_simple_atom_matcher()->add_field_value_matcher(); in TEST() 383 *config.add_atom_matcher() = matcher; in TEST() 388 matcher = CreateSimpleAtomMatcher("TestAtomMatcher", util::TEST_ATOM_REPORTED); in TEST() 389 *config.add_atom_matcher() = matcher; in TEST() 392 *countMetric = createCountMetric("TestCountMetric", matcher.id() /* what */, in TEST() 460 AtomMatcher matcher = CreateAcquireWakelockAtomMatcher(); in TEST() local [all …]
|
/packages/apps/UniversalMediaPlayer/java/com/android/pump/provider/ |
D | Query.java | 122 Matcher matcher = PATTERN_EPISODE.matcher(filePath); in parseEpisode() local 123 if (matcher.find()) { in parseEpisode() 124 MatchResult matchResult = matcher.toMatchResult(); in parseEpisode() 148 Matcher matcher = PATTERN_MOVIE.matcher(filePath); in parseMovie() local 149 if (matcher.find()) { in parseMovie() 150 MatchResult matchResult = matcher.toMatchResult(); in parseMovie() 163 return PATTERN_CLEANUP.matcher(string).replaceAll(" ").trim(); in cleanup()
|
/packages/modules/Virtualization/tests/hostside/helper/java/com/android/microdroid/test/host/ |
D | KvmHypTracer.java | 139 Matcher matcher = LOST_EVENT_PATTERN.matcher(l); in getDurationStats() local 140 if (matcher.find()) in getDurationStats() 141 throw new OutOfMemoryError("Lost " + matcher.group(1) + " events"); in getDurationStats() 143 matcher = EVENT_PATTERN.matcher(l); in getDurationStats() 144 if (!matcher.find()) { in getDurationStats() 149 int cpu = Integer.parseInt(matcher.group(1)); in getDurationStats() 153 double cur = Double.parseDouble(matcher.group(2)); in getDurationStats() 158 String event = matcher.group(3); in getDurationStats()
|
/packages/modules/HealthFitness/apk/tests/src/com/android/healthconnect/controller/tests/utils/ |
D | ViewMatchers.kt | 21 import androidx.test.espresso.matcher.BoundedMatcher 36 fun withIndex(matcher: Matcher<View?>, index: Int): Matcher<View?> { in withIndex() 43 matcher.describeTo(description) in withIndex() 47 return matcher.matches(view) && currentIndex++ == index in withIndex() 95 private fun View.findViewByMatcher(matcher: Matcher<View>): View? { in findViewByMatcher() 96 if (matcher.matches(this)) return this // Check if this view itself matches in findViewByMatcher() 100 val foundView = child.findViewByMatcher(matcher) in findViewByMatcher()
|
/packages/modules/StatsD/statsd/tests/metrics/parsing_utils/ |
D | metrics_manager_util_test.cpp | 1246 AtomMatcher* matcher = config.add_atom_matcher(); in TEST_F() local 1247 matcher->set_id(matcherId); in TEST_F() 1248 matcher->mutable_combination()->add_matcher(StringToId("ScreenTurnedOn")); in TEST_F() 1260 AtomMatcher* matcher = config.add_atom_matcher(); in TEST_F() local 1261 matcher->set_id(matcherId); in TEST_F() 1262 matcher->mutable_combination()->set_operation(LogicalOperation::NOT); in TEST_F() 1263 matcher->mutable_combination()->add_matcher(StringToId("ScreenTurnedOn")); in TEST_F() 1264 matcher->mutable_combination()->add_matcher(StringToId("ScreenTurnedOff")); in TEST_F() 1384 AtomMatcher matcher; in TEST_F() local 1386 matcher.set_id(21); in TEST_F() [all …]
|
/packages/providers/MediaProvider/src/com/android/providers/media/util/ |
D | FileUtils.java | 594 final Matcher dcfStrict = PATTERN_DCF_STRICT.matcher(name); in buildUniqueNameIterator() 613 final Matcher dcfRelaxed = PATTERN_DCF_RELAXED.matcher(name); in buildUniqueNameIterator() 945 return PATTERN_DOWNLOADS_FILE.matcher(path).matches(); 949 return PATTERN_DOWNLOADS_DIRECTORY.matcher(path).matches(); 1082 final Matcher matcher = PATTERN_USER_ID.matcher(data); 1083 if (matcher.find()) { 1084 return Integer.parseInt(matcher.group(1)); 1092 final Matcher matcher = PATTERN_RELATIVE_PATH.matcher(data); 1093 if (matcher.find()) { 1094 return data.substring(0, matcher.end()); [all …]
|
/packages/apps/Car/VoiceControl/src/com/android/car/voicecontrol/actuators/ |
D | Skill.java | 77 Matcher matcher = mPattern.matcher(text); in tryExecute() local 78 if (!matcher.matches()) { in tryExecute() 82 String[] arguments = new String[matcher.groupCount() + 1]; in tryExecute() 83 for (int i = 0; i < matcher.groupCount() + 1; i++) { in tryExecute() 84 arguments[i] = matcher.group(i); in tryExecute()
|
/packages/apps/DocumentsUI/tests/common/com/android/documentsui/bots/ |
D | Matchers.java | 21 import static androidx.test.espresso.matcher.ViewMatchers.isDisplayed; 38 public static boolean present(Matcher<View> matcher) { in present() argument 39 return present(onView(matcher), isDisplayed()); in present() 42 public static boolean present(ViewInteraction vi, Matcher<View> matcher) { in present() argument 44 vi.check(matches(matcher)); in present()
|
/packages/modules/StatsD/statsd/tests/metrics/ |
D | metrics_test_helper.cpp | 46 void buildSimpleAtomFieldMatcher(const int tagId, FieldMatcher* matcher) { in buildSimpleAtomFieldMatcher() argument 47 matcher->set_field(tagId); in buildSimpleAtomFieldMatcher() 50 void buildSimpleAtomFieldMatcher(const int tagId, const int fieldNum, FieldMatcher* matcher) { in buildSimpleAtomFieldMatcher() argument 51 matcher->set_field(tagId); in buildSimpleAtomFieldMatcher() 52 matcher->add_child()->set_field(fieldNum); in buildSimpleAtomFieldMatcher()
|
/packages/modules/StatsD/statsd/src/shell/ |
D | ShellSubscriberClient.cpp | 73 result.pullInfo.emplace_back(pulled.matcher(), startTimeMs, pullIntervalMs, packages, uids); in readConfig() 75 pulled.matcher().atom_id()); in readConfig() 81 ShellSubscriberClient::PullInfo::PullInfo(const SimpleAtomMatcher& matcher, int64_t startTimeMs, in PullInfo() argument 85 : mPullerMatcher(matcher), in PullInfo() 177 const SimpleAtomMatcher& matcher, in writeEventToProtoIfMatched() argument 179 auto [matched, transformedEvent] = matchesSimple(mUidMap, matcher, event); in writeEventToProtoIfMatched() 204 for (const auto& matcher : mPushedMatchers) { in onLogEvent() local 205 if (writeEventToProtoIfMatched(event, matcher, mUidMap)) { in onLogEvent() 297 const SimpleAtomMatcher& matcher) { in writePulledAtomsLocked() argument 300 if (writeEventToProtoIfMatched(*event, matcher, mUidMap)) { in writePulledAtomsLocked() [all …]
|
/packages/apps/Launcher3/tests/multivalentTests/src/com/android/launcher3/settings/ |
D | SettingsActivityTest.java | 25 import static androidx.test.espresso.intent.matcher.BundleMatchers.hasEntry; 26 import static androidx.test.espresso.intent.matcher.IntentMatchers.hasComponent; 27 import static androidx.test.espresso.intent.matcher.IntentMatchers.hasExtra; 28 import static androidx.test.espresso.matcher.ViewMatchers.hasDescendant; 29 import static androidx.test.espresso.matcher.ViewMatchers.isDisplayed; 30 import static androidx.test.espresso.matcher.ViewMatchers.withContentDescription; 31 import static androidx.test.espresso.matcher.ViewMatchers.withId; 32 import static androidx.test.espresso.matcher.ViewMatchers.withText;
|
/packages/apps/Dialer/java/com/android/dialer/i18n/ |
D | DialerBidiFormatter.java | 62 Matcher matcher = Patterns.PHONE.matcher(text.toString()); in format() local 65 while (matcher.find()) { in format() 66 int start = matcher.start(); in format() 67 int end = matcher.end(); in format()
|
/packages/modules/AdServices/adservices/libraries/collectors-helper/adservices/src/com/android/adservices/helpers/ |
D | EpochComputationHelper.java | 61 Matcher matcher = pattern.matcher(line); in processInput() local 62 while (matcher.find()) { in processInput() 67 String metric = matcher.group(1); in processInput() 68 Long latency = Long.parseLong(matcher.group(2)); in processInput()
|