Searched refs:batteryEvent (Results 1 – 4 of 4) sorted by relevance
269 final BatteryEvent batteryEvent = in convertBatteryEventToContentValues_normalCase_returnsExpectedContentValues() local275 final ContentValues values = ConvertUtils.convertBatteryEventToContentValues(batteryEvent); in convertBatteryEventToContentValues_normalCase_returnsExpectedContentValues()557 final BatteryEvent batteryEvent = in convertToBatteryEvent_normalCase_returnsExpectedResult() local559 assertThat(batteryEvent.getTimestamp()).isEqualTo(666L); in convertToBatteryEvent_normalCase_returnsExpectedResult()560 assertThat(batteryEvent.getType()).isEqualTo(BatteryEventType.POWER_DISCONNECTED); in convertToBatteryEvent_normalCase_returnsExpectedResult()561 assertThat(batteryEvent.getBatteryLevel()).isEqualTo(88); in convertToBatteryEvent_normalCase_returnsExpectedResult()
140 final BatteryEvent batteryEvent = in sendBatteryEventData_returnsExpectedList() local148 DatabaseUtils.sendBatteryEventData(mContext, batteryEvent); in sendBatteryEventData_returnsExpectedList()
836 BatteryEvent batteryEvent = batteryEventList.get(index); in excludePowerConnectedTimeFromAppUsagePeriodList() local837 if (batteryEvent.getTimestamp() < inputPeriod.getStartTime()) { in excludePowerConnectedTimeFromAppUsagePeriodList()842 if (batteryEvent.getType() == BatteryEventType.POWER_CONNECTED) { in excludePowerConnectedTimeFromAppUsagePeriodList()844 } else if (batteryEvent.getType() == BatteryEventType.POWER_DISCONNECTED) { in excludePowerConnectedTimeFromAppUsagePeriodList()850 if (batteryEvent.getTimestamp() > inputPeriod.getEndTime()) { in excludePowerConnectedTimeFromAppUsagePeriodList()856 if (batteryEvent.getType() == BatteryEventType.POWER_CONNECTED in excludePowerConnectedTimeFromAppUsagePeriodList()861 .setEndTime(batteryEvent.getTimestamp()) in excludePowerConnectedTimeFromAppUsagePeriodList()864 } else if (batteryEvent.getType() == BatteryEventType.POWER_DISCONNECTED) { in excludePowerConnectedTimeFromAppUsagePeriodList()865 lastStartTime = batteryEvent.getTimestamp(); in excludePowerConnectedTimeFromAppUsagePeriodList()
582 final Context context, final BatteryEvent batteryEvent) { in sendBatteryEventData() argument584 ContentValues contentValues = ConvertUtils.convertBatteryEventToContentValues(batteryEvent); in sendBatteryEventData()588 Log.d(TAG, "insert() battery event data into database: " + batteryEvent.toString()); in sendBatteryEventData()608 batteryEvent -> in sendBatteryEventData()611 batteryEvent))); in sendBatteryEventData()