Home
last modified time | relevance | path

Searched refs:UsageStats (Results 1 – 25 of 27) sorted by relevance

12

/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/
DRecentAppStatsMixinTest.java29 import android.app.usage.UsageStats;
94 final List<UsageStats> stats = new ArrayList<>(); in loadDisplayableRecentApps_oneValidRecentAppSet_shouldHaveOneRecentApp()
95 final UsageStats stat1 = new UsageStats(); in loadDisplayableRecentApps_oneValidRecentAppSet_shouldHaveOneRecentApp()
115 final List<UsageStats> stats = new ArrayList<>(); in loadDisplayableRecentApps_threeValidRecentAppsSet_shouldHaveThreeRecentApps()
116 final UsageStats stat1 = new UsageStats(); in loadDisplayableRecentApps_threeValidRecentAppsSet_shouldHaveThreeRecentApps()
117 final UsageStats stat2 = new UsageStats(); in loadDisplayableRecentApps_threeValidRecentAppsSet_shouldHaveThreeRecentApps()
118 final UsageStats stat3 = new UsageStats(); in loadDisplayableRecentApps_threeValidRecentAppsSet_shouldHaveThreeRecentApps()
150 final List<UsageStats> stats = new ArrayList<>(); in loadDisplayableRecentApps_oneValidAndTwoInvalidSet_shouldHaveOneRecentApp()
151 final UsageStats stat1 = new UsageStats(); in loadDisplayableRecentApps_oneValidAndTwoInvalidSet_shouldHaveOneRecentApp()
152 final UsageStats stat2 = new UsageStats(); in loadDisplayableRecentApps_oneValidAndTwoInvalidSet_shouldHaveOneRecentApp()
[all …]
DRecentAppsPreferenceControllerTest.java32 import android.app.usage.UsageStats;
127 final List<UsageStats> stats = new ArrayList<>(); in onReloadDataCompleted_threeValidRecentOpenAppsSet_setAppEntityThreeTime()
128 final UsageStats stat1 = new UsageStats(); in onReloadDataCompleted_threeValidRecentOpenAppsSet_setAppEntityThreeTime()
129 final UsageStats stat2 = new UsageStats(); in onReloadDataCompleted_threeValidRecentOpenAppsSet_setAppEntityThreeTime()
130 final UsageStats stat3 = new UsageStats(); in onReloadDataCompleted_threeValidRecentOpenAppsSet_setAppEntityThreeTime()
160 final List<UsageStats> stats = new ArrayList<>(); in onReloadDataCompleted_noRecentOpenAppsSet_shouldHideRecentAppPreference()
DAllAppsInfoPreferenceControllerTest.java28 import android.app.usage.UsageStats;
70 final List<UsageStats> stats = new ArrayList<>(); in onReloadDataCompleted_recentAppsSet_hidePreference()
71 final UsageStats stat1 = new UsageStats(); in onReloadDataCompleted_recentAppsSet_hidePreference()
83 final List<UsageStats> stats = new ArrayList<>(); in onReloadDataCompleted_noRecentAppSet_showPreference()
/packages/apps/TvSettings/Settings/tests/robotests/src/com/android/tv/settings/device/apps/
DRecentAppsPreferenceControllerTest.java36 import android.app.usage.UsageStats;
140 final List<UsageStats> stats = new ArrayList<>(); in display_showRecents()
141 final UsageStats stat1 = new UsageStats(); in display_showRecents()
142 final UsageStats stat2 = new UsageStats(); in display_showRecents()
143 final UsageStats stat3 = new UsageStats(); in display_showRecents()
179 final List<UsageStats> stats = new ArrayList<>(); in display_showRecentsWithInstantApp()
180 final UsageStats stat1 = new UsageStats(); in display_showRecentsWithInstantApp()
186 final UsageStats stat2 = new UsageStats(); in display_showRecentsWithInstantApp()
221 final List<UsageStats> stats = new ArrayList<>(); in display_showRecentsWithNullAppEntryOrInfo()
222 final UsageStats stat1 = new UsageStats(); in display_showRecentsWithNullAppEntryOrInfo()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/
DUsageStatsActivity.java20 import android.app.usage.UsageStats;
59 public static class AppNameComparator implements Comparator<UsageStats> {
67 public final int compare(UsageStats a, UsageStats b) { in compare()
74 public static class LastTimeUsedComparator implements Comparator<UsageStats> {
76 public final int compare(UsageStats a, UsageStats b) { in compare()
82 public static class UsageTimeComparator implements Comparator<UsageStats> {
84 public final int compare(UsageStats a, UsageStats b) { in compare()
107 private final ArrayList<UsageStats> mPackageStats = new ArrayList<>();
113 final List<UsageStats> stats = in UsageStatsAdapter()
120 ArrayMap<String, UsageStats> map = new ArrayMap<>(); in UsageStatsAdapter()
[all …]
/packages/apps/Settings/src/com/android/settings/
DUsageStatsActivity.java20 import android.app.usage.UsageStats;
59 public static class AppNameComparator implements Comparator<UsageStats> {
67 public final int compare(UsageStats a, UsageStats b) { in compare()
74 public static class LastTimeUsedComparator implements Comparator<UsageStats> {
76 public final int compare(UsageStats a, UsageStats b) { in compare()
82 public static class UsageTimeComparator implements Comparator<UsageStats> {
84 public final int compare(UsageStats a, UsageStats b) { in compare()
107 private final ArrayList<UsageStats> mPackageStats = new ArrayList<>();
113 final List<UsageStats> stats = in UsageStatsAdapter()
120 ArrayMap<String, UsageStats> map = new ArrayMap<>(); in UsageStatsAdapter()
[all …]
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/device/apps/
DRecentAppsPreferenceController.java20 import android.app.usage.UsageStats;
55 implements Comparator<UsageStats> {
71 private List<UsageStats> mStats;
120 final List<UsageStats> recentApps = getDisplayableRecentAppList(); in refreshUi()
139 private void displayRecentApps(Context prefContext, List<UsageStats> recentApps) { in displayRecentApps()
155 final UsageStats stat = recentApps.get(i); in displayRecentApps()
195 public final int compare(UsageStats a, UsageStats b) { in compare()
209 private List<UsageStats> getDisplayableRecentAppList() { in getDisplayableRecentAppList()
210 final List<UsageStats> recentApps = new ArrayList<>(); in getDisplayableRecentAppList()
211 final Map<String, UsageStats> map = new ArrayMap<>(); in getDisplayableRecentAppList()
[all …]
/packages/apps/Settings/src/com/android/settings/applications/
DRecentAppStatsMixin.java22 import android.app.usage.UsageStats;
52 public class RecentAppStatsMixin implements Comparator<UsageStats>, LifecycleObserver, OnStart {
58 final List<UsageStats> mRecentApps;
104 public final int compare(UsageStats a, UsageStats b) { in compare()
118 final List<UsageStats> mStats = mPowerManager.isPowerSaveMode() in loadDisplayableRecentApps()
124 final Map<String, UsageStats> map = new ArrayMap<>(); in loadDisplayableRecentApps()
127 final UsageStats pkgStats = mStats.get(i); in loadDisplayableRecentApps()
132 final UsageStats existingStats = map.get(pkgName); in loadDisplayableRecentApps()
139 final List<UsageStats> packageStats = new ArrayList<>(); in loadDisplayableRecentApps()
143 for (UsageStats stat : packageStats) { in loadDisplayableRecentApps()
[all …]
DRecentAppsPreferenceController.java20 import android.app.usage.UsageStats;
70 private List<UsageStats> mRecentApps;
111 public void onReloadDataCompleted(@NonNull List<UsageStats> recentApps) { in onReloadDataCompleted()
141 for (UsageStats stat : mRecentApps) { in displayRecentApps()
153 private AppEntityInfo createAppEntity(UsageStats stat) { in createAppEntity()
DAllAppsInfoPreferenceController.java19 import android.app.usage.UsageStats;
56 public void onReloadDataCompleted(@NonNull List<UsageStats> recentApps) { in onReloadDataCompleted()
DAppAndNotificationDashboardFragment.java20 import android.app.usage.UsageStats;
104 public void onReloadDataCompleted(@NonNull List<UsageStats> recentApps) { in onReloadDataCompleted()
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/applications/
DRecentAppStatsMixin.java22 import android.app.usage.UsageStats;
52 public class RecentAppStatsMixin implements Comparator<UsageStats>, LifecycleObserver, OnStart {
58 final List<UsageStats> mRecentApps;
104 public final int compare(UsageStats a, UsageStats b) { in compare()
118 final List<UsageStats> mStats = mPowerManager.isPowerSaveMode() in loadDisplayableRecentApps()
124 final Map<String, UsageStats> map = new ArrayMap<>(); in loadDisplayableRecentApps()
127 final UsageStats pkgStats = mStats.get(i); in loadDisplayableRecentApps()
132 final UsageStats existingStats = map.get(pkgName); in loadDisplayableRecentApps()
139 final List<UsageStats> packageStats = new ArrayList<>(); in loadDisplayableRecentApps()
143 for (UsageStats stat : packageStats) { in loadDisplayableRecentApps()
[all …]
DRecentAppsPreferenceController.java21 import android.app.usage.UsageStats;
70 private List<UsageStats> mRecentApps;
109 public void onReloadDataCompleted(@NonNull List<UsageStats> recentApps) { in onReloadDataCompleted()
138 for (UsageStats stat : mRecentApps) { in displayRecentApps()
150 private AppEntityInfo createAppEntity(UsageStats stat) { in createAppEntity()
DAllAppsInfoPreferenceController.java19 import android.app.usage.UsageStats;
56 public void onReloadDataCompleted(@NonNull List<UsageStats> recentApps) { in onReloadDataCompleted()
DAppAndNotificationDashboardFragment.java20 import android.app.usage.UsageStats;
107 public void onReloadDataCompleted(@NonNull List<UsageStats> recentApps) { in onReloadDataCompleted()
/packages/apps/StorageManager/src/com/android/storagemanager/deletionhelper/
DAppsAsyncLoader.java19 import android.app.usage.UsageStats;
104 final Map<String, UsageStats> map = in loadApps()
106 final Map<String, UsageStats> alternateMap = in loadApps()
120 UsageStats usageStats = map.get(app.packageName); in loadApps()
121 UsageStats alternateUsageStats = alternateMap.get(app.packageName); in loadApps()
160 UsageStats getGreaterUsageStats(String packageName, UsageStats primary, UsageStats alternate) { in getGreaterUsageStats()
179 private Map<String, UsageStats> getLatestUsageStatsByPackageName(long startTime, long endTime) { in getLatestUsageStatsByPackageName()
180 List<UsageStats> usageStats = in getLatestUsageStatsByPackageName()
183 Map<String, List<UsageStats>> groupedByPackageName = in getLatestUsageStatsByPackageName()
184 usageStats.stream().collect(Collectors.groupingBy(UsageStats::getPackageName)); in getLatestUsageStatsByPackageName()
[all …]
DAppStateUsageStatsBridge.java18 import android.app.usage.UsageStats;
73 final Map<String, UsageStats> map = getAggregatedUsageStats(); in loadAllExtraInfo()
75 UsageStats usageStats = map.get(entry.info.packageName); in loadAllExtraInfo()
84 Map<String, UsageStats> map = getAggregatedUsageStats(); in updateExtraInfo()
85 UsageStats usageStats = map.get(app.info.packageName); in updateExtraInfo()
91 private long getDaysSinceLastUse(UsageStats stats) { in getDaysSinceLastUse()
123 private Map<String, UsageStats> getAggregatedUsageStats() { in getAggregatedUsageStats()
/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/
DMetadataEntryParserTest.java25 import com.android.providers.contacts.MetadataEntryParser.UsageStats;
94 UsageStats usageStats1_1 = new UsageStats(usageType1_1, lastTimeUsed1_1, timesUsed1_1); in testParseDataToMetadataEntry()
95 UsageStats usageStats1_2 = new UsageStats(usageType1_2, lastTimeUsed1_2, timesUsed1_2); in testParseDataToMetadataEntry()
96 UsageStats usageStats2 = new UsageStats(usageType2, lastTimeUsed2, timesUsed2); in testParseDataToMetadataEntry()
98 ArrayList<UsageStats> usageStats1List = new ArrayList<>(); in testParseDataToMetadataEntry()
103 ArrayList<UsageStats> usageStats2List = new ArrayList<>(); in testParseDataToMetadataEntry()
291 private void assertUsageStatsListEquals(ArrayList<UsageStats> usageStatsList1, in assertUsageStatsListEquals()
292 ArrayList<UsageStats> usageStatsList2) { in assertUsageStatsListEquals()
299 private void assertUsageStatsEquals(UsageStats usageStats1, UsageStats usageStats2) { in assertUsageStatsEquals()
/packages/apps/StorageManager/robotests/src/com/android/storagemanager/deletionhelper/
DAppsAsyncLoaderTest.java19 import android.app.usage.UsageStats;
71 private HashMap<String, UsageStats> mUsageStats;
306 UsageStats secondary = mock(UsageStats.class); in test_getGreaterUsageStats_primaryIsNull()
314 UsageStats primary = mock(UsageStats.class); in test_getGreaterUsageStats_secondaryIsNull()
321 UsageStats primary = mock(UsageStats.class); in test_getGreaterUsageStats_primaryIsGreater()
323 UsageStats secondary = mock(UsageStats.class); in test_getGreaterUsageStats_primaryIsGreater()
331 UsageStats primary = mock(UsageStats.class); in test_getGreaterUsageStats_secondaryIsGreater()
333 UsageStats secondary = mock(UsageStats.class); in test_getGreaterUsageStats_secondaryIsGreater()
388 UsageStats usageStats = mock(UsageStats.class); in registerLastUse()
DAppStateUsageStatsBridgeTest.java19 import android.app.usage.UsageStats;
67 private HashMap<String, UsageStats> mUsageStats;
412 UsageStats usageStats = mock(UsageStats.class); in registerLastUse()
/packages/providers/ContactsProvider/src/com/android/providers/contacts/
DMetadataEntryParser.java62 public static class UsageStats { class in MetadataEntryParser
71 public UsageStats(String usageType, long lastTimeUsed, int timesUsed) { in UsageStats() method in MetadataEntryParser.UsageStats
87 final ArrayList<UsageStats> mUsageStatsList;
91 ArrayList<UsageStats> usageStatsList) { in FieldData()
230 final ArrayList<UsageStats> usageStatsList = new ArrayList<UsageStats>(); in parseDataToMetaDataEntry()
242 final UsageStats usageStatsParsed = new UsageStats( in parseDataToMetaDataEntry()
/packages/apps/Car/Launcher/src/com/android/car/carlauncher/
DAppGridActivity.java23 import android.app.usage.UsageStats;
302 List<UsageStats> stats = in getMostRecentApps()
319 UsageStats usageStats = stats.get(currentIndex); in getMostRecentApps()
372 private static class LastTimeUsedComparator implements Comparator<UsageStats> {
374 public int compare(UsageStats stat1, UsageStats stat2) { in compare()
/packages/apps/PermissionController/src/com/android/permissioncontroller/permission/data/
DUsageStatsLiveData.kt20 import android.app.usage.UsageStats in <lambda>()
40 ) : SmartAsyncMediatorLiveData<Map<UserHandle, List<UsageStats>>>() { in <lambda>()
54 val userMap = mutableMapOf<UserHandle, List<UsageStats>>() in <lambda>()
/packages/modules/ExtServices/tests/src/android/ext/services/storage/
DCacheQuotaServiceImplTest.java24 import android.app.usage.UsageStats;
148 UsageStats stats = new UsageStats(); in makeNewRequest()
/packages/apps/PermissionController/src/com/android/permissioncontroller/permission/service/
DAutoRevokePermissions.kt41 import android.app.usage.UsageStats in <lambda>()
434 private fun List<UsageStats>.lastTimeVisible(pkgNames: List<String>): Long { in List()
444 private fun List<UsageStats>.lastTimeVisible(pkgName: String): Long { in List()

12