GetMedicalDataSourcesRequest.Builder
public
static
final
class
GetMedicalDataSourcesRequest.Builder
extends Object
java.lang.Object | |
↳ | android.health.connect.GetMedicalDataSourcesRequest.Builder |
Builder class for GetMedicalDataSourcesRequest
.
Summary
Public constructors | |
---|---|
Builder()
Constructs a new |
|
Builder(GetMedicalDataSourcesRequest other)
Constructs a clone of the other |
|
Builder(GetMedicalDataSourcesRequest.Builder other)
Constructs a clone of the other |
Public methods | |
---|---|
GetMedicalDataSourcesRequest.Builder
|
addPackageName(String packageName)
Adds a package name to limit this request to. |
GetMedicalDataSourcesRequest
|
build()
Returns a new instance of |
GetMedicalDataSourcesRequest.Builder
|
clearPackageNames()
Clears all package names. |
Inherited methods | |
---|---|
Public constructors
Builder
public Builder ()
Constructs a new GetMedicalDataSourcesRequest.Builder
with no filters set.
Builder
public Builder (GetMedicalDataSourcesRequest other)
Constructs a clone of the other GetMedicalDataSourcesRequest
instance.
Parameters | |
---|---|
other |
GetMedicalDataSourcesRequest : This value cannot be null . |
Builder
public Builder (GetMedicalDataSourcesRequest.Builder other)
Constructs a clone of the other GetMedicalDataSourcesRequest.Builder
.
Parameters | |
---|---|
other |
GetMedicalDataSourcesRequest.Builder : This value cannot be null . |
Public methods
addPackageName
public GetMedicalDataSourcesRequest.Builder addPackageName (String packageName)
Adds a package name to limit this request to.
If the list of package names is empty, MedicalDataSource
s for all packages
will be requested. Otherwise only those for the added package names are requested.
Parameters | |
---|---|
packageName |
String : This value cannot be null . |
Returns | |
---|---|
GetMedicalDataSourcesRequest.Builder |
This value cannot be null . |
Throws | |
---|---|
IllegalArgumentException |
if the provided packageName is not valid. |
build
public GetMedicalDataSourcesRequest build ()
Returns a new instance of GetMedicalDataSourcesRequest
with the specified
parameters.
Returns | |
---|---|
GetMedicalDataSourcesRequest |
This value cannot be null . |
clearPackageNames
public GetMedicalDataSourcesRequest.Builder clearPackageNames ()
Clears all package names.
Returns | |
---|---|
GetMedicalDataSourcesRequest.Builder |
This value cannot be null . |