History log of /frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
0b575a3cdfce8cd5394044c4c6a7092487ba93cb 16-Apr-2018 Makoto Onuki <omakoto@google.com> Split provider / service dumpsys into platform and non-platform

Also extend the timeout to 60 seconds.
- Because each provider / service dump may time out, the total time should relatively be large.

Bug: 78017892
Fix: 78017892

Test: Manual test with the following dumpsys commands:
dumpsys activity provider all
dumpsys activity provider all-platform
dumpsys activity provider all-non-platform
dumpsys activity provider com.android.providers.contacts/com.android.providers.contacts.VoicemailContentProvider
dumpsys activity provider com.android.providers.contacts/.VoicemailContentProvider
dumpsys activity provider contacts
dumpsys activity provider voicemail
dumpsys activity provider 4d45a78

dumpsys activity service all
dumpsys activity service all-platform
dumpsys activity service all-non-platform
dumpsys activity service bluetooth

Test: atest /android/pi-dev/frameworks/base/core/tests/coretests/src/com/android/internal/util/DumpTest.java
Test: atest /android/pi-dev/frameworks/base/core/tests/coretests/src/com/android/internal/util/ParseUtilsTest.java

Test: Manual test with "adb bugreport" with adding sleep(10s) to ProviderMap.dumpProvider()

Change-Id: I00bce0090b8dbb947d7f8b1e5d01bb8a70d84bd8
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
32697552f2dcebf1e718687402f5728b0ec109db 31-Jan-2018 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Minor optimization for CollectionUtils.mapNotNull"
1abf48e8c0643b318e42e8b4786175792ea43ca1 03-Jan-2018 Eugene Susla <eugenesusla@google.com> Concise toString for A11yEvent

I found A11yEvents hard to parse in logs as they take ~3 lines on my
30" monitor, most of which denoting fields that rarely differ from default.

This CL adds an opt-in debug flag to not print default-valued fields, which
dramatically cuts down the noise when trying to parse logs.

Test: enable DEBUG in A11yManager, and observe logcat
Change-Id: I979200194ee3597c1a8501195437b4d4b8e21514
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
4b7c919e725bc87bea82ab2c2370f094a049b8cf 07-Dec-2017 Eugene Susla <eugenesusla@google.com> Communicate relevantEvents=0 for packages excluded from whitelist

Together with checking isObservableEventType this will result in a11y events
not being generated for packages that are excluded form a11y-service(s)
package whitelist

Test: cts-tradefed run singleCommand cts -d --module CtsAccessibilityServiceTestCases
Change-Id: Id65607aaccc7af7d870d009d609917ff3c6d0712
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
72b5616890c1b309f5a5115b90ee7e333f322930 06-Dec-2017 Eugene Susla <eugenesusla@google.com> Minor optimization for CollectionUtils.mapNotNull

Test: presubmit
Change-Id: Ibdafa1d37e09a4e326e0c5c4a4696fc954437ba0
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
2f5ee71ec851b1149b4e10ec211ad520cd73776e 24-Jun-2017 Eugene Susla <eugenesusla@google.com> PooledLambda

This introduces PooledLambda - a way of obtaining lambdas without the
allocations overhead.

See PooledLambda javadoc for a guide and PooledLambdaSample for code samples
of useful usages.

Test: ensure samples of PooledLambdaSample work as described.
Change-Id: I46f8ad27bc1de07e19f6e39f89d2cafe4238497a
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
67f9d5070a74a0bf34f0335899a96dedcac26c96 05-Aug-2017 Jeff Sharkey <jsharkey@android.com> Fix broken javadocs.

Bug: 64337634
Test: make -j32 doc-comment-check-docs
Change-Id: I20fdd3dcddef09111d35946c41c596c7689effa6
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
612311ef41ea2304c7d487b321b88c60fbfe9d6c 06-Jul-2017 Eugene Susla <eugenesusla@google.com> [Companion] Dont store duplicate association records

Fixes: 62675985
Test: Assosiate the same item twice and ensure getAssociations lists it
only once
Change-Id: I028c08010740baaa04464647dffa701fc066a4fe
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
bc278909914fc5685c609d6270f983c6adebc036 14-Jun-2017 Eugene Susla <eugenesusla@google.com> Merge "Support associating with an already-paired device" into oc-dev am: c041c7a34e am: c26f789ae2
am: dfa5272295

Change-Id: Ic68002087eacf339356e13e10698d88e1ff30c40
0c4a9266264d37e724f7372ef7ef932cf60c505c 10-Jun-2017 Eugene Susla <eugenesusla@google.com> Support associating with an already-paired device

This is required for migration scenario, where device(s) are already
paired(and thus no longer discoverable) but didn't go through companion
flow.
This also fixes a bug with filtering by mac address, which is also relevant to
the use-case of associating a specific device

Test: Pair with a device first, and call associate with a filter with its MAC
address and single device requested. Ensure the device is found.
Ensure only that device is ever returned when filtering by MAC address.
Bug: 62487084
Change-Id: Ic7cc6affc0648ad85b15620e8c3aba4b9fc91aa1
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
554edd35ecb4dede0201a79a83a9da04c331b0be 25-May-2017 Eugene Susla <eugenesusla@google.com> Serialize all standard actions as bit mask

As described in the attached bug, all(not just legacy) AccessibilityNodeInfo
standard actions can be serialized into a bit mask. This implements that.

Fixes: 33949542
Test: cts-tradefed run singleCommand cts -d --module CtsAccessibilityServiceTestCases
cts-tradefed run singleCommand cts -d --module CtsAccessibilityTestCases
cts-tradefed run singleCommand cts -d --module CtsUiAutomationTestCases
Change-Id: I0619ee33de3051d582420d4aef135205a9ec7e8c
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
cf00adebec29d4cdbec5bc0f004b26a09327c236 10-Apr-2017 Eugene Susla <eugenesusla@google.com> API for notification listener for Companioon apps

Test: 1. Trigger the confitrmation dialog.
Ensure it looks exactly like the one from settings.
2. Call an API without associating the appa first
Ensure exception is thrown with a message mentioning the need to associate 1st
Change-Id: I94d4116e1988db869ed445ae3fd018c50590e3f4
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
4df89bcb31cde334dc317cce705a75b0ff036a8a 29-Mar-2017 Eugene Susla <eugenesusla@google.com> [DO NOT MERGE] Fix associations serialization optimization bug

There mas a missing defensive copy causing false positive detections of
"associations not changed" case, leading to xml file not being updated once
at least one record is present

Bug: 30932767
Test: Associate at least two different devices and ensure the xml has both.
Change-Id: Ic0dc615dd2b847e137555c1084c616831b4dde83
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java
6a7006a9683ba5a79ca338050c7c50b346b04de0 13-Mar-2017 Eugene Susla <eugenesusla@google.com> Register PackageMonitor for CompanionDeviceManagerService

1. On package removed -> remove all its associations
2. On package updated -> if had associations, update special access permission
in accordance with (potentially changed) permission entries in manifest

Bug: 30932767
Test: 1. Remove app, and ensure xml entries for it got removed.
2. adb install new version of app without special permissions in manifest, and
ensure whitelist removal method got called
Change-Id: I87261c05ddcf40a18332d160b44ee2f8284df5e4
/frameworks/base/core/java/com/android/internal/util/CollectionUtils.java