ChangedDataRequest

Represents a request for a read query over a period of time to retrieve a list of changed HealthDataPoints.

This request can include a changeTimeFilter. All changes, such as upserted data points or deleted data uids, can be obtained within the time range specified in this filter.

This request will always retrieve data of all sources.

This is the sample code for reading sleep data changes:

suspend fun readSleepDataChanges() {
     val healthDataStore = HealthDataService.getStore(context)
     val changeRequest = DataTypes.SLEEP.changedDataRequestBuilder
         // set a time filter or another condition
         .build()

     // make asynchronous call for result
     val result = healthDataStore.readChanges(changeRequest)
     // process data
}

Since

1.0.0

Types

Link copied to clipboard

A basic builder to create a ChangedDataRequest instance.

Properties

Link copied to clipboard

Retrieves the InstantTimeFilter for filtering the change time of this request.

Link copied to clipboard

Retrieves the data type of this request.

Link copied to clipboard

Retrieves the page size of this request, which means the size of data in one results page.

Link copied to clipboard

Retrieves the page token of this request.

Preferences Submitted

You have successfully updated your cookie preferences.