com.samsung.android.sdk.healthdata
Interface HealthConstants.HeartRate
-
- All Superinterfaces:
- HealthConstants.Common, HealthConstants.SessionMeasurement
- Enclosing class:
- HealthConstants
public static interface HealthConstants.HeartRate extends HealthConstants.SessionMeasurement
This interface defines heart rate data of the user.Properties
Properties of the following extending interfaces are available for this data type.
Heart rate data has the following properties.
See more common properties by spreading this section out.Property name Description HealthConstants.HeartRate.DEVICE_UUID [Mandatory]
Device identifier which provides the health dataHealthConstants.HeartRate.START_TIME [Mandatory]
UTC milliseconds when the measurement is startedHealthConstants.HeartRate.END_TIME [Mandatory]
UTC milliseconds after the measurement has endedHealthConstants.HeartRate.TIME_OFFSET [Mandatory]
Time offset in milliseconds which considers the time zone and daylight saving timeHealthConstants.HeartRate.HEART_RATE [Mandatory]
Heart rate valueHealthConstants.HeartRate.HEART_BEAT_COUNT Total heart beat count for measurement time HealthConstants.HeartRate.MIN Min value in BINNING_DATA
HealthConstants.HeartRate.MAX Max value in BINNING_DATA
HealthConstants.HeartRate.BINNING_DATA Continuous heart rate HealthConstants.HeartRate.COMMENT Comment HealthConstants.HeartRate.CUSTOM Custom info which is formatted with JSON and compressed data Data Permission
The user's consent is required to read or write this data type. HealthPermissionManager.requestPermissions() displays a data permission UI to the user.
See Permission Manager and request data permission.- Since:
- 1.0.0
-
-
Field Summary
Fields Modifier and Type Field and Description static String
BINNING_DATA
Continuous heart rate which is formatted with JSON and compressed data.static String
COMMENT
Comment for data.static String
HEALTH_DATA_TYPE
Data type name for heart rate data.static String
HEART_BEAT_COUNT
Total heart beat count for measurement time.static String
HEART_RATE
Heart rate value, beats per minute (bpm).static String
MAX
Max value inBINNING_DATA
.static String
MIN
Min value inBINNING_DATA
.-
Fields inherited from interface com.samsung.android.sdk.healthdata.HealthConstants.SessionMeasurement
END_TIME, START_TIME, TIME_OFFSET
-
Fields inherited from interface com.samsung.android.sdk.healthdata.HealthConstants.Common
CREATE_TIME, CUSTOM, DEVICE_UUID, PACKAGE_NAME, UPDATE_TIME, UUID
-
-
-
-
Field Detail
-
HEART_RATE
static final String HEART_RATE
Heart rate value, beats per minute (bpm).- Mandatory
- Type:
float
- Value range: 0 ~ 300
- Since:
- 1.0.0
- See Also:
- Constant Field Values
-
HEART_BEAT_COUNT
static final String HEART_BEAT_COUNT
Total heart beat count for measurement time.- Mandatory
- Type:
int
- Value range: 0 and above
- Since:
- 1.0.0
- See Also:
- Constant Field Values
-
COMMENT
static final String COMMENT
Comment for data.- Optional
- Type:
String
- Value length: 0 ~ 255
- Since:
- 1.0.0
- See Also:
- Constant Field Values
-
MIN
static final String MIN
Min value inBINNING_DATA
.- Optional
- Type:
float
- Value range: 0 ~ 300
- Since:
- 1.3.0
- See Also:
- Constant Field Values
-
MAX
static final String MAX
Max value inBINNING_DATA
.- Optional
- Type:
float
- Value range: 0 ~ 300
- Since:
- 1.3.0
- See Also:
- Constant Field Values
-
BINNING_DATA
static final String BINNING_DATA
Continuous heart rate which is formatted with JSON and compressed data.- Optional
- Type:
byte[]
- Maximum data size: 1000 KB
Binning data can have one or more segment.
Each segment is composed of the following JSON Keys.JSON key Type Unit Mandatory "heart_rate" float
Beat per minute Yes.
Set this value if you saveBINNING_DATA
."heart_rate_min" float
Beat per minute Yes.
Set this value if you saveBINNING_DATA
."heart_rate_max" float
Beat per minute Yes.
Set this value if you saveBINNING_DATA
."start_time" long
UTC millisecond Yes.
Set this value if you saveBINNING_DATA
."end_time" long
UTC millisecond Yes.
Set this value if you saveBINNING_DATA
.The following example shows the JSON format for
BINNING_DATA
.{ "heart_rate":147.48181, "heart_rate_min":99.0, "heart_rate_max":124.0, "start_time":1422457096536, "end_time":1493922600000 }
Compressed JSON conversion can be:
- Since:
- 1.3.0
- See Also:
HealthDataUtil
, Constant Field Values
-
HEALTH_DATA_TYPE
static final String HEALTH_DATA_TYPE
Data type name for heart rate data.
Use"com.samsung.health.heart_rate"
to add permission to the manifest file.- Since:
- 1.0.0
- See Also:
- Constant Field Values
-
-