Builder


class Builder
kotlin.Any
   ↳ android.health.connect.ReadMedicalResourcesPageRequest.Builder

Builder class for ReadMedicalResourcesPageRequest.

Summary

Public constructors

Constructs a clone of the other ReadMedicalResourcesPageRequest instance.

Constructs a clone of the other ReadMedicalResourcesPageRequest.Builder.

Builder(pageToken: String)

Constructs a new ReadMedicalResourcesPageRequest instance.

Public methods
ReadMedicalResourcesPageRequest

Returns a new instance of ReadMedicalResourcesPageRequest with the specified parameters.

ReadMedicalResourcesPageRequest.Builder
setPageSize(pageSize: Int)

Sets the maximum number of MedicalResources to be returned by the read operation.

ReadMedicalResourcesPageRequest.Builder
setPageToken(pageToken: String)

Sets page token to read the requested page of the result, from the previous android.health.connect.ReadMedicalResourcesResponse#getNextPageToken().

Public constructors

Builder

Builder(other: ReadMedicalResourcesPageRequest)

Constructs a clone of the other ReadMedicalResourcesPageRequest instance.

Parameters
other ReadMedicalResourcesPageRequest: This value cannot be null.

Builder

Builder(other: ReadMedicalResourcesPageRequest.Builder)

Constructs a clone of the other ReadMedicalResourcesPageRequest.Builder.

Parameters
other ReadMedicalResourcesPageRequest.Builder: This value cannot be null.

Builder

Builder(pageToken: String)

Constructs a new ReadMedicalResourcesPageRequest instance.

Parameters
pageToken String: The page token to read the requested page of the result, from the previous ReadMedicalResourcesResponse.getNextPageToken(). This value cannot be null.

Public methods

build

fun build(): ReadMedicalResourcesPageRequest

Returns a new instance of ReadMedicalResourcesPageRequest with the specified parameters.

Return
ReadMedicalResourcesPageRequest This value cannot be null.

setPageSize

fun setPageSize(pageSize: Int): ReadMedicalResourcesPageRequest.Builder

Sets the maximum number of MedicalResources to be returned by the read operation.

If not set, default to 1000.

Parameters
pageSize Int: Value is between MINIMUM_PAGE_SIZE and MAXIMUM_PAGE_SIZE inclusive
Return
ReadMedicalResourcesPageRequest.Builder This value cannot be null.
Exceptions
java.lang.IllegalArgumentException if the provided pageSize is less than 1 or more than 5000.

setPageToken

fun setPageToken(pageToken: String): ReadMedicalResourcesPageRequest.Builder

Sets page token to read the requested page of the result, from the previous android.health.connect.ReadMedicalResourcesResponse#getNextPageToken().

Parameters
pageToken String: This value cannot be null.
Return
ReadMedicalResourcesPageRequest.Builder This value cannot be null.