Class SessionSample
java.lang.Object
com.codename1.health.HealthSample
com.codename1.health.SessionSample
- Direct Known Subclasses:
NutritionSample, SleepSample, WorkoutSample
A bounded activity that groups child data -- a workout, a night's sleep, a logged meal.
Sessions are always intervals: HealthSample.isInstantaneous() is
false for every subclass.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedSessionSample(HealthDataType type, long startMillis, long endMillis) Creates a session spanning[startMillis, endMillis]. -
Method Summary
Methods inherited from class HealthSample
equals, getDurationMillis, getEndMillis, getId, getMetadata, getRecordingMethod, getSource, getStartMillis, getType, hashCode, isInstantaneous, putMetadata, setId, setRecordingMethod, setSource, toString
-
Constructor Details
-
SessionSample
Creates a session spanning[startMillis, endMillis].
-
-
Method Details
-
getTitle
A user-visible title, or null. Health Connect stores this natively; on iOS it is carried in sample metadata. -
setTitle
Sets the user-visible title. -
getNotes
Free-form user notes, or null. -
setNotes
Sets free-form user notes.
-