healbesdk / com.healbe.healbesdk.business_api.healthdata.data.stress / StressData

StressData

data class StressData : SampleData

Sample data with information of stress during measurement period.

Properties

calculating

val calculating: Boolean

stress module was adjusted to user during measurement period

isStrongEmoTension

val isStrongEmoTension: Boolean

is user experiences strong emotions during measurement period

stressLevel

val stressLevel: Float

Average stress level during measurement period.

timestampEnd

val timestampEnd: Long

End of the sample in UNIX-timestamp.

timestampStart

val timestampStart: Long

Beginning of the sample in UNIX-timestamp.

Functions

toStressLevel

fun toStressLevel(): StressLevel

Convert stressLevel numerical value into StressLevel

toStressState

fun toStressState(): StressState

Convert stressLevel numerical value into StressState

Companion Object Properties

DANGER_LEVEL

const val DANGER_LEVEL: Float

Minimum value for StressLevel.DANGER level

EMPTY

val EMPTY: StressData

Value for no data state

HIGH_LEVEL

const val HIGH_LEVEL: Float

Minimum value for StressLevel.HIGH level

MAX_LEVEL

const val MAX_LEVEL: Float

Maximum stress level

MIN_LEVEL

const val MIN_LEVEL: Float

Minimum stress value

Extension Functions

getSampleDuration

fun SampleData.getSampleDuration(units: TimeUnit = TimeUnit.SECONDS): Long

Returns sample duration in specified units. Default units: TimeUnit.SECONDS.