Home
last modified time | relevance | path

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

12

/packages/modules/HealthFitness/tests/cts/src/android/healthconnect/cts/datatypes/
DExerciseCompletionGoalTest.java212 assertThat(new ExerciseCompletionGoal.TotalCaloriesBurnedGoal(Energy.fromCalories(100))) in totalCaloriesBurnedGoal_equalsAndHashCode()
215 Energy.fromCalories(200))); in totalCaloriesBurnedGoal_equalsAndHashCode()
216 assertThat(new ExerciseCompletionGoal.TotalCaloriesBurnedGoal(Energy.fromCalories(100))) in totalCaloriesBurnedGoal_equalsAndHashCode()
219 Energy.fromCalories(100))); in totalCaloriesBurnedGoal_equalsAndHashCode()
222 new ExerciseCompletionGoal.TotalCaloriesBurnedGoal(Energy.fromCalories(100)) in totalCaloriesBurnedGoal_equalsAndHashCode()
225 new ExerciseCompletionGoal.TotalCaloriesBurnedGoal(Energy.fromCalories(200)) in totalCaloriesBurnedGoal_equalsAndHashCode()
228 new ExerciseCompletionGoal.TotalCaloriesBurnedGoal(Energy.fromCalories(100)) in totalCaloriesBurnedGoal_equalsAndHashCode()
231 new ExerciseCompletionGoal.TotalCaloriesBurnedGoal(Energy.fromCalories(100)) in totalCaloriesBurnedGoal_equalsAndHashCode()
240 Energy.fromCalories(260))); in totalCaloriesBurnedGoal_insertionAndRead()
253 new ExerciseCompletionGoal.TotalCaloriesBurnedGoal(Energy.fromCalories(200)); in totalCaloriesBurnedGoal_getterMethods()
[all …]
DActiveCaloriesBurnedRecordTest.java94 Energy.fromCalories(1000000001.0)) in testCreateActiveCaloriesBurnedRecord_invalidValue()
355 Energy.fromCalories(10.0)); in testZoneOffsets()
579 Energy.fromCalories(20.0)) in getActiveCaloriesBurnedRecord_update()
590 Energy.fromCalories(10.0)) in getBaseActiveCaloriesBurnedRecord()
599 Energy.fromCalories(energy)) in getBaseActiveCaloriesBurnedRecord()
621 Energy.fromCalories(10.0)) in getCompleteActiveCaloriesBurnedRecord()
DTotalCaloriesBurnedRecordTest.java244 Energy.fromCalories(10.0)); in testZoneOffsets()
455 Energy.fromCalories(1000000001.0)) in testCreateTotalCaloriesBurnedRecord_invalidValue()
475 Energy.fromCalories(20.0)) in getTotalCaloriesBurnedRecord_update()
499 Energy.fromCalories(10.0)) in getCompleteTotalCaloriesBurnedRecord()
510 Energy.fromCalories(10.0)) in getBaseTotalCaloriesBurnedRecord()
DNutritionRecordTest.java815 .setEnergyFromFat(Energy.fromCalories(0.1)) in getNutritionRecord_update()
828 .setEnergy(Energy.fromCalories(0.1)) in getNutritionRecord_update()
887 .setEnergyFromFat(Energy.fromCalories(0.1)) in getCompleteNutritionRecord()
900 .setEnergy(Energy.fromCalories(0.1)) in getCompleteNutritionRecord()
/packages/modules/HealthFitness/tests/cts/src/android/healthconnect/cts/datatypes/units/
DEnergyTest.java34 assertThat(Energy.fromCalories(10.0)).isInstanceOf(Energy.class); in testCreate()
35 assertThat(Energy.fromCalories(10.0).getInCalories()).isEqualTo(10.0); in testCreate()
40 Energy Energy1 = Energy.fromCalories(10.0); in testEquals()
41 Energy Energy2 = Energy.fromCalories(10.0); in testEquals()
42 Energy Energy3 = Energy.fromCalories(20.0); in testEquals()
50 Energy Energy1 = Energy.fromCalories(10.0); in testCompare()
51 Energy Energy2 = Energy.fromCalories(10.0); in testCompare()
52 Energy Energy3 = Energy.fromCalories(20.0); in testCompare()
/packages/modules/HealthFitness/apk/tests/src/com/android/healthconnect/controller/tests/dataentries/formatters/
DNutritionFormatterTest.kt82 val record = getBuilder().setEnergy(fromCalories(1234567.0)).build() in <lambda>()
90 val record = getBuilder().setEnergy(fromCalories(1234567.0)).build() in <lambda>()
99 val record = getBuilder().setEnergy(fromCalories(295000.0)).build() in <lambda>()
107 val record = getBuilder().setEnergy(fromCalories(295000.0)).build() in <lambda>()
121 .setEnergyFromFat(fromCalories(30000.0)) in <lambda>()
122 .setEnergy(fromCalories(30000.0)) in <lambda>()
DActiveCaloriesBurnedFormatterTest.kt87 getMetaData(), NOW, NOW.plusSeconds(1), Energy.fromCalories(calories)) in getActiveCaloriesBurnedRecord()
DTotalCaloriesBurnedFormatterTest.kt87 getMetaData(), NOW, NOW.plusSeconds(1), Energy.fromCalories(calories)) in getTotalCaloriesBurnedRecord()
/packages/modules/HealthFitness/tests/unittests/src/android/healthconnect/internal/datatypes/
DExerciseCompletionGoalInternalTest.java143 new TotalCaloriesBurnedGoalInternal(Energy.fromCalories(400.0)); in totalCaloriesBurnedGoal_writeToParcelThenRestore_objectsAreIdentical()
158 new TotalCaloriesBurnedGoalInternal(Energy.fromCalories(500)); in totalCaloriesBurnedGoal_convertToExternalAndBack_objectsAreIdentical()
171 new ActiveCaloriesBurnedGoalInternal(Energy.fromCalories(400.0)); in activeCaloriesBurnedGoal_writeToParcelThenRestore_objectsAreIdentical()
186 new ActiveCaloriesBurnedGoalInternal(Energy.fromCalories(500)); in activeCaloriesBurnedGoal_convertToExternalAndBack_objectsAreIdentical()
/packages/modules/HealthFitness/tests/cts/src/android/healthconnect/cts/aggregation/
DTotalCaloriesAggregationTest.java349 getEmptyMetadata(), start, end, Energy.fromCalories(calories)) in getTotalCaloriesBurnedRecord()
365 Energy.fromCalories(value)); in getBaseTotalCaloriesBurnedRecord()
379 Energy.fromCalories(energy)) in getBaseActiveCaloriesBurnedRecord()
389 Energy.fromCalories(energy)) in getBaseActiveCaloriesBurnedRecord()
DDataFactory.java47 getEmptyMetadata(), start, end, Energy.fromCalories(energy)) in getActiveCaloriesBurnedRecord()
DAggregateOtherAppsDataTest.java115 ENERGY_TOTAL, Energy.fromCalories(10), record.getStartTime(), record.getEndTime()); in testAppWithReadPerms_aggregateOtherAppsTotalCaloriesBurned_expectSuccess()
/packages/modules/HealthFitness/testapps/toolbox/src/com/android/healthconnect/testapps/toolbox/utils/
DInsertOrUpdateRecords.kt200 Energy.fromCalories( in createRecordObjectHelper()
278 Energy.fromCalories( in createRecordObjectHelper()
644 Energy.fromCalories( in createRecordObjectHelper()
652 Energy.fromCalories( in createRecordObjectHelper()
/packages/modules/HealthFitness/framework/java/android/health/connect/datatypes/units/
DEnergy.java38 public static Energy fromCalories(double value) { in fromCalories() method in Energy
/packages/modules/HealthFitness/framework/java/android/health/connect/internal/datatypes/
DTotalCaloriesBurnedRecordInternal.java52 Energy.fromCalories(getEnergy())) in toExternalRecord()
DActiveCaloriesBurnedRecordInternal.java52 Energy.fromCalories(getEnergy())) in toExternalRecord()
DExerciseCompletionGoalInternal.java274 return new TotalCaloriesBurnedGoalInternal(Energy.fromCalories(parcel.readDouble())); in readFieldsFromParcel()
312 return new ActiveCaloriesBurnedGoalInternal(Energy.fromCalories(parcel.readDouble())); in readFieldsFromParcel()
DNutritionRecordInternal.java579 .setEnergyFromFat(Energy.fromCalories(getEnergyFromFat())) in toExternalRecord()
592 .setEnergy(Energy.fromCalories(getEnergy())) in toExternalRecord()
/packages/modules/HealthFitness/service/java/com/android/server/healthconnect/storage/datatypehelpers/
DPlannedExerciseSessionRecordHelper.java329 Energy.fromCalories( in extractCompletionGoal()
333 Energy.fromCalories( in extractCompletionGoal()
/packages/modules/HealthFitness/apk/tests/src/com/android/healthconnect/controller/tests/data/entries/api/
DLoadDataAggregationsUseCaseTest.kt231 val aggregationResult = AggregateResult(Energy.fromCalories(1500000.0)) in <lambda>()
/packages/modules/HealthFitness/framework/java/android/health/connect/datatypes/
DNutritionRecord.java36 private static final Energy ENERGY_0_0 = Energy.fromCalories(0.0);
1431 energyFromFat, ENERGY_0_0, Energy.fromCalories(100000000.0), "energyFromFat"); in NutritionRecord()
1444 requireInRangeIfExists(energy, ENERGY_0_0, Energy.fromCalories(100000000.0), "energy"); in NutritionRecord()
/packages/modules/HealthFitness/tests/integrationtests/src/android/healthconnect/tests/backuprestore/
DBackupRestoreE2ETest.java334 Energy.fromCalories(10.0)) in getCompleteActiveCaloriesBurnedRecord()
/packages/modules/HealthFitness/apk/tests/src/com/android/healthconnect/controller/tests/utils/
DTestConstants.kt142 Energy.fromCalories(Random.nextDouble(1500.0, 5000.0)), date.randomInstant()) in getRandomRecord()
/packages/modules/HealthFitness/framework/java/android/health/connect/internal/datatypes/utils/
DAggregationTypeIdMapper.java283 return new AggregateResult<>(Energy.fromCalories(result)); in getEnergyResult()
/packages/modules/HealthFitness/tests/cts/utils/HealthConnectTestUtils/src/android/healthconnect/cts/utils/
DDataFactory.java589 metadata, NOW, NOW.plusMillis(1000), Energy.fromCalories(10.0)) in getTotalCaloriesBurnedRecord()

12