MenstruationFlowRecord.Builder

public static final class MenstruationFlowRecord.Builder
extends Object

java.lang.Object
   ↳ android.health.connect.datatypes.MenstruationFlowRecord.Builder


Builder class for MenstruationFlowRecord

Summary

Public constructors

Builder(Metadata metadata, Instant time, int flow)

Public methods

MenstruationFlowRecord build()
MenstruationFlowRecord.Builder clearZoneOffset()

Sets the zone offset of this record to system default.

MenstruationFlowRecord.Builder setZoneOffset(ZoneOffset zoneOffset)

Sets the zone offset of the user when the activity happened

Inherited methods

Public constructors

Builder

Added in API level 34
public Builder (Metadata metadata, 
                Instant time, 
                int flow)

Parameters
metadata Metadata: Metadata to be associated with the record. See Metadata. This value cannot be null.

time Instant: Start time of this activity This value cannot be null.

flow int: How heavy the user's menstrual flow was. Optional field. Allowed values: MenstruationFlowType. Value is MenstruationFlowRecord.MenstruationFlowType.FLOW_UNKNOWN, MenstruationFlowRecord.MenstruationFlowType.FLOW_LIGHT, MenstruationFlowRecord.MenstruationFlowType.FLOW_MEDIUM, or MenstruationFlowRecord.MenstruationFlowType.FLOW_HEAVY

Public methods

build

Added in API level 34
public MenstruationFlowRecord build ()

Returns
MenstruationFlowRecord Object of MenstruationFlowRecord This value cannot be null.

clearZoneOffset

Added in API level 34
public MenstruationFlowRecord.Builder clearZoneOffset ()

Sets the zone offset of this record to system default.

Returns
MenstruationFlowRecord.Builder This value cannot be null.

setZoneOffset

Added in API level 34
public MenstruationFlowRecord.Builder setZoneOffset (ZoneOffset zoneOffset)

Sets the zone offset of the user when the activity happened

Parameters
zoneOffset ZoneOffset: This value cannot be null.

Returns
MenstruationFlowRecord.Builder This value cannot be null.