Home
last modified time | relevance | path

Searched refs:energyConsumer (Results 1 – 5 of 5) sorted by relevance

/frameworks/base/services/core/java/com/android/server/powerstats/
DProtoStreamUtils.java434 public static byte[] getProtoBytes(EnergyConsumer[] energyConsumer) { in getProtoBytes() argument
436 packProtoMessage(energyConsumer, pos); in getProtoBytes()
440 public static void packProtoMessage(EnergyConsumer[] energyConsumer, in packProtoMessage() argument
442 if (energyConsumer == null) return; in packProtoMessage()
444 for (int i = 0; i < energyConsumer.length; i++) { in packProtoMessage()
446 pos.write(EnergyConsumerProto.ID, energyConsumer[i].id); in packProtoMessage()
447 pos.write(EnergyConsumerProto.ORDINAL, energyConsumer[i].ordinal); in packProtoMessage()
448 pos.write(EnergyConsumerProto.TYPE, energyConsumer[i].type); in packProtoMessage()
449 pos.write(EnergyConsumerProto.NAME, energyConsumer[i].name); in packProtoMessage()
461 EnergyConsumer energyConsumer = new EnergyConsumer(); in unpackProtoMessage() local
[all …]
DPowerStatsLogger.java186 EnergyConsumer[] energyConsumer = mPowerStatsHALWrapper.getEnergyConsumerInfo(); in writeModelDataToFile() local
187 EnergyConsumerUtils.packProtoMessage(energyConsumer, pos); in writeModelDataToFile()
188 if (DEBUG) EnergyConsumerUtils.print(energyConsumer); in writeModelDataToFile()
DPowerStatsService.java182 EnergyConsumer[] energyConsumer = getPowerStatsHal().getEnergyConsumerInfo(); in dump() local
183 EnergyConsumerUtils.dumpsys(energyConsumer, pw); in dump()
/frameworks/base/tools/powerstats/
DPowerStatsServiceProtoParser.java65 EnergyConsumerProto energyConsumer = proto.getEnergyConsumer(i); in printEnergyConsumer() local
66 csvHeader += "Index,Timestamp," + energyConsumer.getId() + "/" in printEnergyConsumer()
67 + energyConsumer.getOrdinal() + "/" in printEnergyConsumer()
68 + energyConsumer.getType() + "/" in printEnergyConsumer()
69 + energyConsumer.getName() + ","; in printEnergyConsumer()
/frameworks/base/services/tests/servicestests/src/com/android/server/powerstats/
DPowerStatsServiceTest.java354 assertTrue(pssProto.energyConsumer.length == ENERGY_CONSUMER_COUNT); in testWrittenModelDataMatchesReadIncidentReportData()
355 for (int i = 0; i < pssProto.energyConsumer.length; i++) { in testWrittenModelDataMatchesReadIncidentReportData()
356 assertTrue(pssProto.energyConsumer[i].id == i); in testWrittenModelDataMatchesReadIncidentReportData()
505 assertTrue(pssProto.energyConsumer.length == ENERGY_CONSUMER_COUNT); in testCorruptOnDeviceModelStorage()
506 for (int i = 0; i < pssProto.energyConsumer.length; i++) { in testCorruptOnDeviceModelStorage()
507 assertTrue(pssProto.energyConsumer[i].id == i); in testCorruptOnDeviceModelStorage()
640 assertTrue(pssProto.energyConsumer.length == ENERGY_CONSUMER_COUNT); in testNotEnoughBytesAfterModelLengthField()
641 for (int i = 0; i < pssProto.energyConsumer.length; i++) { in testNotEnoughBytesAfterModelLengthField()
642 assertTrue(pssProto.energyConsumer[i].id == i); in testNotEnoughBytesAfterModelLengthField()