Home
last modified time | relevance | path

Searched refs:ConvertUtils (Results 1 – 25 of 38) sorted by relevance

12

/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/batteryusage/
DConvertUtilsTest.java74 ConvertUtils.sUsageSource = ConvertUtils.EMPTY_USAGE_SOURCE; in setUp()
98 .thenReturn(ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in convertBatteryEntryToContentValues_appEntry_returnsExpectedContentValues()
101 ConvertUtils.convertBatteryEntryToContentValues( in convertBatteryEntryToContentValues_appEntry_returnsExpectedContentValues()
111 ConvertUtils.getBatteryInformation( in convertBatteryEntryToContentValues_appEntry_returnsExpectedContentValues()
122 .isEqualTo(ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in convertBatteryEntryToContentValues_appEntry_returnsExpectedContentValues()
164 .thenReturn(ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY); in convertBatteryEntryToContentValues_systemEntry_returnsExpectedContentValues()
167 ConvertUtils.convertBatteryEntryToContentValues( in convertBatteryEntryToContentValues_systemEntry_returnsExpectedContentValues()
177 ConvertUtils.getBatteryInformation( in convertBatteryEntryToContentValues_systemEntry_returnsExpectedContentValues()
187 .isEqualTo(ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY); in convertBatteryEntryToContentValues_systemEntry_returnsExpectedContentValues()
215 ConvertUtils.convertBatteryEntryToContentValues( in convertBatteryEntryToContentValues_nullBatteryEntry_returnsExpectedContentValues()
[all …]
DBatteryHistEntryTest.java18 import static com.android.settings.fuelgauge.batteryusage.ConvertUtils.isSystemConsumer;
19 import static com.android.settings.fuelgauge.batteryusage.ConvertUtils.isUidConsumer;
20 import static com.android.settings.fuelgauge.batteryusage.ConvertUtils.isUserConsumer;
72 .thenReturn(ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY); in testConstructor_contentValues_returnsExpectedResult()
74 ConvertUtils.convertBatteryEntryToContentValues( in testConstructor_contentValues_returnsExpectedResult()
119 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in testGetKey_consumerUidType_returnExpectedString()
129 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_USER_BATTERY); in testGetKey_consumerUserType_returnExpectedString()
139 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY); in testGetKey_consumerSystemType_returnExpectedString()
144 ConvertUtils.convertBatteryInformationToString(batteryInformation)); in testGetKey_consumerSystemType_returnExpectedString()
154 createEntry(ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY) in testIsAppEntry_returnExpectedResult()
[all …]
DBatteryDiffEntryTest.java114 /*consumerType*/ ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in testSetTotalConsumePower_returnExpectedResult()
141 /*consumerType*/ ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in testSetTotalConsumePower_setZeroValue_returnsZeroValue()
170 /*consumerType*/ ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in testComparator_sortCollectionsInDescOrder()
200 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY); in testLoadLabelAndIcon_forSystemBattery_returnExpectedResult()
207 ConvertUtils.convertBatteryInformationToString(batteryInformation)); in testLoadLabelAndIcon_forSystemBattery_returnExpectedResult()
231 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_USER_BATTERY); in testLoadLabelAndIcon_forUserBattery_returnExpectedResult()
256 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in testGetAppLabel_loadDataFromApplicationInfo()
281 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in testGetAppLabel_loadDataFromPreDefinedNameAndUid()
298 getContentValuesWithType(ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in testGetAppLabel_nullAppLabel_returnAppLabelInBatteryHistEntry()
303 ConvertUtils.convertBatteryInformationToString(batteryInformation)); in testGetAppLabel_nullAppLabel_returnAppLabelInBatteryHistEntry()
[all …]
DDataProcessorTest.java19 import static com.android.settings.fuelgauge.batteryusage.ConvertUtils.FAKE_PACKAGE_NAME;
903 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in getBatteryDiffDataMap_normalFlow_returnExpectedResult()
920 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in getBatteryDiffDataMap_normalFlow_returnExpectedResult()
937 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in getBatteryDiffDataMap_normalFlow_returnExpectedResult()
994 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in generateBatteryUsageMap_returnsExpectedResult()
1011 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in generateBatteryUsageMap_returnsExpectedResult()
1035 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in generateBatteryUsageMap_returnsExpectedResult()
1055 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in generateBatteryUsageMap_returnsExpectedResult()
1071 ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY, in generateBatteryUsageMap_returnsExpectedResult()
1087 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in generateBatteryUsageMap_returnsExpectedResult()
[all …]
DBatteryDiffDataTest.java84 Set.of(ConvertUtils.FAKE_PACKAGE_NAME), in needsCombineInSystemApp_isSystemApp_returnTrue()
186 ConvertUtils.FAKE_PACKAGE_NAME, in createBatteryDiffEntry()
195 ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in createBatteryDiffEntry()
254 ConvertUtils.convertBatteryInformationToString(batteryInformation)); in createBatteryHistEntry()
DDatabaseUtilsTest.java401 "app name1", timestamp1, 1, ConvertUtils.CONSUMER_TYPE_UID_BATTERY, true in getHistoryMap_returnExpectedMap()
405 "app name2", timestamp2, 2, ConvertUtils.CONSUMER_TYPE_UID_BATTERY, false in getHistoryMap_returnExpectedMap()
409 "app name3", timestamp2, 3, ConvertUtils.CONSUMER_TYPE_UID_BATTERY, false in getHistoryMap_returnExpectedMap()
413 "app name4", timestamp2, 4, ConvertUtils.CONSUMER_TYPE_UID_BATTERY, false in getHistoryMap_returnExpectedMap()
562 ConvertUtils.getBatteryInformation( in verifyBatteryEntryContentValues()
575 ConvertUtils.getBatteryInformation( in verifyFakeBatteryEntryContentValues()
583 assertThat(values.getAsString("packageName")).isEqualTo(ConvertUtils.FAKE_PACKAGE_NAME); in verifyFakeBatteryEntryContentValues()
DBatteryUsageBreakdownControllerTest.java102 /* consumerType= */ ConvertUtils.CONSUMER_TYPE_UID_BATTERY, in setUp()
238 mBatteryDiffEntry.mConsumerType = ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY; in handlePreferenceTreeClick_forAppEntry_returnTrue()
256 mBatteryDiffEntry.mConsumerType = ConvertUtils.CONSUMER_TYPE_UID_BATTERY; in handlePreferenceTreeClick_forSystemEntry_returnTrue()
456 ? ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY in createBatteryDiffEntry()
457 : ConvertUtils.CONSUMER_TYPE_UID_BATTERY)); in createBatteryDiffEntry()
/packages/apps/Settings/src/com/android/settings/fuelgauge/batteryusage/db/
DBatteryReattributeEntity.java19 import static com.android.settings.fuelgauge.batteryusage.ConvertUtils.utcToLocalTimeForLogging;
22 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
47 ConvertUtils.encodeBatteryReattribute(batteryReattribute)); in BatteryReattributeEntity()
62 ConvertUtils.decodeBatteryReattribute(reattributeData); in toString()
DBatteryUsageSlotEntity.java24 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
61 final String recordAtDateTime = ConvertUtils.utcToLocalTimeForLogging(timestamp); in toString()
DBatteryEventEntity.java24 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
65 final String recordAtDateTime = ConvertUtils.utcToLocalTimeForLogging(timestamp); in toString()
DAppUsageEventEntity.java24 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
84 final String recordAtDateTime = ConvertUtils.utcToLocalTimeForLogging(timestamp); in toString()
DBatteryState.java26 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
92 final String recordAtDateTime = ConvertUtils.utcToLocalTimeForLogging(timestamp); in toString()
/packages/apps/Settings/src/com/android/settings/fuelgauge/batteryusage/
DBatteryHistEntry.java61 @ConvertUtils.ConsumerType public final int mConsumerType;
77 ConvertUtils.getBatteryInformation(values, KEY_BATTERY_INFORMATION); in BatteryHistEntry()
107 ConvertUtils.getBatteryInformation(cursor, KEY_BATTERY_INFORMATION); in BatteryHistEntry()
178 case ConvertUtils.CONSUMER_TYPE_UID_BATTERY: in getKey()
181 case ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY: in getKey()
184 case ConvertUtils.CONSUMER_TYPE_USER_BATTERY: in getKey()
194 final String recordAtDateTime = ConvertUtils.utcToLocalTimeForLogging(mTimestamp); in toString()
DBatteryDiffData.java19 import static com.android.settings.fuelgauge.batteryusage.ConvertUtils.utcToLocalTimeForLogging;
165 || ConvertUtils.FAKE_PACKAGE_NAME.equals(packageName) in purgeBatteryDiffData()
198 ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in combineIntoSystemApps()
228 ConvertUtils.CONSUMER_TYPE_UID_BATTERY); in combineIntoUninstalledApps()
263 ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY); in combineSystemItemsIntoOthers()
DDatabaseUtils.java19 import static com.android.settings.fuelgauge.batteryusage.ConvertUtils.utcToLocalTimeForLogging;
219 context, appUsageEventUri, ConvertUtils::convertToAppUsageEvent); in getAppUsageEventForUsers()
257 context, batteryEventUri, ConvertUtils::convertToBatteryEvent); in getBatteryEvents()
286 context, batteryUsageSlotUri, ConvertUtils::convertToBatteryUsageSlot); in getBatteryUsageSlots()
556 ConvertUtils.convertAppUsageEventToContentValues( in sendAppUsageEventData()
584 ContentValues contentValues = ConvertUtils.convertBatteryEventToContentValues(batteryEvent); in sendBatteryEventData()
610 ConvertUtils.convertBatteryEventToContentValues( in sendBatteryEventData()
644 ConvertUtils.convertBatteryUsageSlotToContentValues( in sendBatteryUsageSlotData()
718 ConvertUtils.convertBatteryEntryToContentValues( in sendBatteryEntryData()
749 ConvertUtils.convertBatteryEntryToContentValues( in sendBatteryEntryData()
[all …]
DBatteryDiffEntry.java297 case ConvertUtils.CONSUMER_TYPE_USER_BATTERY: in isSystemEntry()
298 case ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY: in isSystemEntry()
300 case ConvertUtils.CONSUMER_TYPE_UID_BATTERY: in isSystemEntry()
376 case ConvertUtils.CONSUMER_TYPE_USER_BATTERY: in loadLabelAndIcon()
386 case ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY: in loadLabelAndIcon()
398 case ConvertUtils.CONSUMER_TYPE_UID_BATTERY: in loadLabelAndIcon()
DBatteryUsageDataLoader.java76 ConvertUtils.convertToBatteryEvent( in loadBatteryStatsData()
133 ConvertUtils.convertToBatteryUsageSlotList( in preprocessBatteryUsageSlots()
157 context, ConvertUtils.convertToBatteryEventList(batteryLevelData)); in preprocessBatteryUsageSlots()
DBatteryEntry.java111 @ConvertUtils.ConsumerType private final int mConsumerType;
163 mConsumerType = ConvertUtils.CONSUMER_TYPE_UID_BATTERY; in BatteryEntry()
216 mConsumerType = ConvertUtils.CONSUMER_TYPE_USER_BATTERY; in BatteryEntry()
242 mConsumerType = ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY; in BatteryEntry()
268 mConsumerType = ConvertUtils.CONSUMER_TYPE_SYSTEM_BATTERY; in BatteryEntry()
279 @ConvertUtils.ConsumerType
/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/batteryusage/db/
DBatteryStateTest.java24 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
80 .isEqualTo(ConvertUtils.convertBatteryInformationToString(mBatteryInformation)); in testBuilder_returnsExpectedResult()
92 ConvertUtils.convertBatteryInformationToString(batteryInformation)) in create()
DBatteryReattributeEntityTest.java22 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
51 ConvertUtils.decodeBatteryReattribute(batteryReattributeEntity.reattributeData); in constructor_createExpectedData()
/packages/apps/TV/tuner/src/com/android/tv/tuner/util/
DConvertUtils.java20 public class ConvertUtils { class
24 private ConvertUtils() {} in ConvertUtils() method in ConvertUtils
/packages/apps/Settings/src/com/android/settings/fuelgauge/batteryusage/bugreport/
DBatteryUsageLogUtils.java27 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
95 .append(ConvertUtils.utcToLocalTimeForLogging(entry.getTimestamp())) in toString()
DLogUtils.java28 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
89 ConvertUtils.utcToLocalTimeForLogging(timestamp); in dumpBatteryUsageDatabaseHist()
/packages/apps/Settings/src/com/android/settings/fuelgauge/
DBatteryOptimizeLogUtils.java26 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
111 ConvertUtils.utcToLocalTimeForLogging(entry.getTimestamp()), in toString()
/packages/apps/Settings/tests/robotests/src/com/android/settings/testutils/
DBatteryTestUtils.java36 import com.android.settings.fuelgauge.batteryusage.ConvertUtils;
150 ConvertUtils.convertBatteryInformationToString(batteryInformation), in insertDataToBatteryStateTable()

12