Class Profile.Builder (0.2.0)

public static final class Profile.Builder extends GeneratedMessage.Builder<Profile.Builder> implements ProfileOrBuilder

Profile details.

Protobuf type google.devicesandservices.health.v4.Profile

Implements

ProfileOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

build()

public Profile build()
Returns
Type Description
Profile

buildPartial()

public Profile buildPartial()
Returns
Type Description
Profile

clear()

public Profile.Builder clear()
Returns
Type Description
Profile.Builder
Overrides

clearAge()

public Profile.Builder clearAge()

Optional. The age in years based on the user's birth date.

Updates to this field are currently not supported.

int32 age = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Profile.Builder

This builder for chaining.

clearAutoRunningStrideLengthMm()

public Profile.Builder clearAutoRunningStrideLengthMm()

Output only. The automatically calculated running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_running_stride_length_mm = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Profile.Builder

This builder for chaining.

clearAutoWalkingStrideLengthMm()

public Profile.Builder clearAutoWalkingStrideLengthMm()

Output only. The automatically calculated walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_walking_stride_length_mm = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Profile.Builder

This builder for chaining.

clearMembershipStartDate()

public Profile.Builder clearMembershipStartDate()

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Profile.Builder

clearName()

public Profile.Builder clearName()

Identifier. The resource name of this Profile resource.

Format: users/{user}/profile Example: users/1234567890/profile or users/me/profile The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal me can also be used to refer to the authenticated user.

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
Profile.Builder

This builder for chaining.

clearUserConfiguredRunningStrideLengthMm()

public Profile.Builder clearUserConfiguredRunningStrideLengthMm()

Optional. The user's user configured running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_running_stride_length_mm = 14 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Profile.Builder

This builder for chaining.

clearUserConfiguredWalkingStrideLengthMm()

public Profile.Builder clearUserConfiguredWalkingStrideLengthMm()

Optional. The user's user configured walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_walking_stride_length_mm = 13 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Profile.Builder

This builder for chaining.

getAge()

public int getAge()

Optional. The age in years based on the user's birth date.

Updates to this field are currently not supported.

int32 age = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The age.

getAutoRunningStrideLengthMm()

public int getAutoRunningStrideLengthMm()

Output only. The automatically calculated running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_running_stride_length_mm = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The autoRunningStrideLengthMm.

getAutoWalkingStrideLengthMm()

public int getAutoWalkingStrideLengthMm()

Output only. The automatically calculated walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_walking_stride_length_mm = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The autoWalkingStrideLengthMm.

getDefaultInstanceForType()

public Profile getDefaultInstanceForType()
Returns
Type Description
Profile

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getMembershipStartDate()

public Date getMembershipStartDate()

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
com.google.type.Date

The membershipStartDate.

getMembershipStartDateBuilder()

public Date.Builder getMembershipStartDateBuilder()

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
com.google.type.Date.Builder

getMembershipStartDateOrBuilder()

public DateOrBuilder getMembershipStartDateOrBuilder()

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
com.google.type.DateOrBuilder

getName()

public String getName()

Identifier. The resource name of this Profile resource.

Format: users/{user}/profile Example: users/1234567890/profile or users/me/profile The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal me can also be used to refer to the authenticated user.

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Identifier. The resource name of this Profile resource.

Format: users/{user}/profile Example: users/1234567890/profile or users/me/profile The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal me can also be used to refer to the authenticated user.

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
ByteString

The bytes for name.

getUserConfiguredRunningStrideLengthMm()

public int getUserConfiguredRunningStrideLengthMm()

Optional. The user's user configured running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_running_stride_length_mm = 14 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The userConfiguredRunningStrideLengthMm.

getUserConfiguredWalkingStrideLengthMm()

public int getUserConfiguredWalkingStrideLengthMm()

Optional. The user's user configured walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_walking_stride_length_mm = 13 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The userConfiguredWalkingStrideLengthMm.

hasAutoRunningStrideLengthMm()

public boolean hasAutoRunningStrideLengthMm()

Output only. The automatically calculated running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_running_stride_length_mm = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the autoRunningStrideLengthMm field is set.

hasAutoWalkingStrideLengthMm()

public boolean hasAutoWalkingStrideLengthMm()

Output only. The automatically calculated walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_walking_stride_length_mm = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the autoWalkingStrideLengthMm field is set.

hasMembershipStartDate()

public boolean hasMembershipStartDate()

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the membershipStartDate field is set.

hasUserConfiguredRunningStrideLengthMm()

public boolean hasUserConfiguredRunningStrideLengthMm()

Optional. The user's user configured running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_running_stride_length_mm = 14 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the userConfiguredRunningStrideLengthMm field is set.

hasUserConfiguredWalkingStrideLengthMm()

public boolean hasUserConfiguredWalkingStrideLengthMm()

Optional. The user's user configured walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_walking_stride_length_mm = 13 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the userConfiguredWalkingStrideLengthMm field is set.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(Profile other)

public Profile.Builder mergeFrom(Profile other)
Parameter
Name Description
other Profile
Returns
Type Description
Profile.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Profile.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Profile.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public Profile.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
Profile.Builder
Overrides

mergeMembershipStartDate(Date value)

public Profile.Builder mergeMembershipStartDate(Date value)

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value com.google.type.Date
Returns
Type Description
Profile.Builder

setAge(int value)

public Profile.Builder setAge(int value)

Optional. The age in years based on the user's birth date.

Updates to this field are currently not supported.

int32 age = 6 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The age to set.

Returns
Type Description
Profile.Builder

This builder for chaining.

setAutoRunningStrideLengthMm(int value)

public Profile.Builder setAutoRunningStrideLengthMm(int value)

Output only. The automatically calculated running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_running_stride_length_mm = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value int

The autoRunningStrideLengthMm to set.

Returns
Type Description
Profile.Builder

This builder for chaining.

setAutoWalkingStrideLengthMm(int value)

public Profile.Builder setAutoWalkingStrideLengthMm(int value)

Output only. The automatically calculated walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 auto_walking_stride_length_mm = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value int

The autoWalkingStrideLengthMm to set.

Returns
Type Description
Profile.Builder

This builder for chaining.

setMembershipStartDate(Date value)

public Profile.Builder setMembershipStartDate(Date value)

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value com.google.type.Date
Returns
Type Description
Profile.Builder

setMembershipStartDate(Date.Builder builderForValue)

public Profile.Builder setMembershipStartDate(Date.Builder builderForValue)

Output only. The date the user created their account.

Updates to this field are currently not supported.

.google.type.Date membership_start_date = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
builderForValue com.google.type.Date.Builder
Returns
Type Description
Profile.Builder

setName(String value)

public Profile.Builder setName(String value)

Identifier. The resource name of this Profile resource.

Format: users/{user}/profile Example: users/1234567890/profile or users/me/profile The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal me can also be used to refer to the authenticated user.

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
Profile.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Profile.Builder setNameBytes(ByteString value)

Identifier. The resource name of this Profile resource.

Format: users/{user}/profile Example: users/1234567890/profile or users/me/profile The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal me can also be used to refer to the authenticated user.

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
Profile.Builder

This builder for chaining.

setUserConfiguredRunningStrideLengthMm(int value)

public Profile.Builder setUserConfiguredRunningStrideLengthMm(int value)

Optional. The user's user configured running stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_running_stride_length_mm = 14 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The userConfiguredRunningStrideLengthMm to set.

Returns
Type Description
Profile.Builder

This builder for chaining.

setUserConfiguredWalkingStrideLengthMm(int value)

public Profile.Builder setUserConfiguredWalkingStrideLengthMm(int value)

Optional. The user's user configured walking stride length, in millimeters.

The user must consent to one of the following access scopes to access this field:

- https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly

optional int32 user_configured_walking_stride_length_mm = 13 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The userConfiguredWalkingStrideLengthMm to set.

Returns
Type Description
Profile.Builder

This builder for chaining.