public final class Exercise extends GeneratedMessage implements ExerciseOrBuilder
An exercise that stores information about a physical activity.
Protobuf type google.devicesandservices.health.v4.Exercise
Inherited Members
com.google.protobuf.GeneratedMessage.<ContainingT,T>newFileScopedGeneratedExtension(java.lang.Class<?>,com.google.protobuf.Message)
com.google.protobuf.GeneratedMessage.<ContainingT,T>newMessageScopedGeneratedExtension(com.google.protobuf.Message,int,java.lang.Class<?>,com.google.protobuf.Message)
com.google.protobuf.GeneratedMessage.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessage.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessage.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessage.<V>serializeBooleanMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Boolean,V>,com.google.protobuf.MapEntry<java.lang.Boolean,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeIntegerMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Integer,V>,com.google.protobuf.MapEntry<java.lang.Integer,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeLongMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Long,V>,com.google.protobuf.MapEntry<java.lang.Long,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeStringMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.String,V>,com.google.protobuf.MapEntry<java.lang.String,V>,int)
com.google.protobuf.GeneratedMessage.canUseUnsafe()
com.google.protobuf.GeneratedMessage.emptyBooleanList()
com.google.protobuf.GeneratedMessage.emptyDoubleList()
com.google.protobuf.GeneratedMessage.emptyFloatList()
com.google.protobuf.GeneratedMessage.emptyIntList()
com.google.protobuf.GeneratedMessage.emptyLongList()
com.google.protobuf.GeneratedMessage.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessage.isStringEmpty(java.lang.Object)
com.google.protobuf.GeneratedMessage.mergeFromAndMakeImmutableInternal(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite)
com.google.protobuf.GeneratedMessage.newInstance(com.google.protobuf.GeneratedMessage.UnusedPrivateParameter)
com.google.protobuf.GeneratedMessage.parseUnknownFieldProto3(com.google.protobuf.CodedInputStream,com.google.protobuf.UnknownFieldSet.Builder,com.google.protobuf.ExtensionRegistryLite,int)
Static Fields
ACTIVE_DURATION_FIELD_NUMBER
public static final int ACTIVE_DURATION_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
CREATE_TIME_FIELD_NUMBER
public static final int CREATE_TIME_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
DISPLAY_NAME_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
EXERCISE_EVENTS_FIELD_NUMBER
public static final int EXERCISE_EVENTS_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
public static final int EXERCISE_METADATA_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
EXERCISE_TYPE_FIELD_NUMBER
public static final int EXERCISE_TYPE_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
INTERVAL_FIELD_NUMBER
public static final int INTERVAL_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
METRICS_SUMMARY_FIELD_NUMBER
public static final int METRICS_SUMMARY_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
NOTES_FIELD_NUMBER
public static final int NOTES_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
SPLITS_FIELD_NUMBER
public static final int SPLITS_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
SPLIT_SUMMARIES_FIELD_NUMBER
public static final int SPLIT_SUMMARIES_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
UPDATE_TIME_FIELD_NUMBER
public static final int UPDATE_TIME_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
Static Methods
getDefaultInstance()
public static Exercise getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static Exercise.Builder newBuilder()
newBuilder(Exercise prototype)
public static Exercise.Builder newBuilder(Exercise prototype)
| Parameter |
| Name |
Description |
prototype |
Exercise
|
public static Exercise parseDelimitedFrom(InputStream input)
public static Exercise parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static Exercise parseFrom(byte[] data)
| Parameter |
| Name |
Description |
data |
byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Exercise parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static Exercise parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Exercise parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Exercise parseFrom(CodedInputStream input)
public static Exercise parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static Exercise parseFrom(InputStream input)
public static Exercise parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static Exercise parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Exercise parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<Exercise> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
| Parameter |
| Name |
Description |
obj |
Object
|
Overrides
getActiveDuration()
public Duration getActiveDuration()
Optional. Duration excluding pauses.
.google.protobuf.Duration active_duration = 13 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
Duration |
The activeDuration.
|
getActiveDurationOrBuilder()
public DurationOrBuilder getActiveDurationOrBuilder()
Optional. Duration excluding pauses.
.google.protobuf.Duration active_duration = 13 [(.google.api.field_behavior) = OPTIONAL];
getCreateTime()
public Timestamp getCreateTime()
Output only. Represents the timestamp of the creation of the exercise.
.google.protobuf.Timestamp create_time = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
Timestamp |
The createTime.
|
getCreateTimeOrBuilder()
public TimestampOrBuilder getCreateTimeOrBuilder()
Output only. Represents the timestamp of the creation of the exercise.
.google.protobuf.Timestamp create_time = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];
getDefaultInstanceForType()
public Exercise getDefaultInstanceForType()
getDisplayName()
public String getDisplayName()
Required. Exercise display name.
string display_name = 12 [(.google.api.field_behavior) = REQUIRED];
| Returns |
| Type |
Description |
String |
The displayName.
|
getDisplayNameBytes()
public ByteString getDisplayNameBytes()
Required. Exercise display name.
string display_name = 12 [(.google.api.field_behavior) = REQUIRED];
| Returns |
| Type |
Description |
ByteString |
The bytes for displayName.
|
getExerciseEvents(int index)
public Exercise.ExerciseEvent getExerciseEvents(int index)
Optional. Exercise events that happen during an exercise, such as pause &
restarts.
repeated .google.devicesandservices.health.v4.Exercise.ExerciseEvent exercise_events = 15 [(.google.api.field_behavior) = OPTIONAL];
| Parameter |
| Name |
Description |
index |
int
|
getExerciseEventsCount()
public int getExerciseEventsCount()
Optional. Exercise events that happen during an exercise, such as pause &
restarts.
repeated .google.devicesandservices.health.v4.Exercise.ExerciseEvent exercise_events = 15 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
int |
|
getExerciseEventsList()
public List<Exercise.ExerciseEvent> getExerciseEventsList()
Optional. Exercise events that happen during an exercise, such as pause &
restarts.
repeated .google.devicesandservices.health.v4.Exercise.ExerciseEvent exercise_events = 15 [(.google.api.field_behavior) = OPTIONAL];
getExerciseEventsOrBuilder(int index)
public Exercise.ExerciseEventOrBuilder getExerciseEventsOrBuilder(int index)
Optional. Exercise events that happen during an exercise, such as pause &
restarts.
repeated .google.devicesandservices.health.v4.Exercise.ExerciseEvent exercise_events = 15 [(.google.api.field_behavior) = OPTIONAL];
| Parameter |
| Name |
Description |
index |
int
|
getExerciseEventsOrBuilderList()
public List<? extends Exercise.ExerciseEventOrBuilder> getExerciseEventsOrBuilderList()
Optional. Exercise events that happen during an exercise, such as pause &
restarts.
repeated .google.devicesandservices.health.v4.Exercise.ExerciseEvent exercise_events = 15 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
List<? extends com.google.devicesandservices.health.v4.Exercise.ExerciseEventOrBuilder> |
|
public Exercise.ExerciseMetadata getExerciseMetadata()
Optional. Additional exercise metadata.
.google.devicesandservices.health.v4.Exercise.ExerciseMetadata exercise_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];
public Exercise.ExerciseMetadataOrBuilder getExerciseMetadataOrBuilder()
Optional. Additional exercise metadata.
.google.devicesandservices.health.v4.Exercise.ExerciseMetadata exercise_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];
getExerciseType()
public Exercise.ExerciseType getExerciseType()
Required. The type of activity performed during an exercise.
.google.devicesandservices.health.v4.Exercise.ExerciseType exercise_type = 6 [(.google.api.field_behavior) = REQUIRED];
getExerciseTypeValue()
public int getExerciseTypeValue()
Required. The type of activity performed during an exercise.
.google.devicesandservices.health.v4.Exercise.ExerciseType exercise_type = 6 [(.google.api.field_behavior) = REQUIRED];
| Returns |
| Type |
Description |
int |
The enum numeric value on the wire for exerciseType.
|
getInterval()
public SessionTimeInterval getInterval()
Required. Observed exercise interval
.google.devicesandservices.health.v4.SessionTimeInterval interval = 2 [(.google.api.field_behavior) = REQUIRED];
getIntervalOrBuilder()
public SessionTimeIntervalOrBuilder getIntervalOrBuilder()
Required. Observed exercise interval
.google.devicesandservices.health.v4.SessionTimeInterval interval = 2 [(.google.api.field_behavior) = REQUIRED];
getMetricsSummary()
public MetricsSummary getMetricsSummary()
Required. Summary metrics for this exercise
( )
.google.devicesandservices.health.v4.MetricsSummary metrics_summary = 10 [(.google.api.field_behavior) = REQUIRED];
getMetricsSummaryOrBuilder()
public MetricsSummaryOrBuilder getMetricsSummaryOrBuilder()
Required. Summary metrics for this exercise
( )
.google.devicesandservices.health.v4.MetricsSummary metrics_summary = 10 [(.google.api.field_behavior) = REQUIRED];
getNotes()
Optional. Standard free-form notes captured at manual logging.
string notes = 14 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
String |
The notes.
|
getNotesBytes()
public ByteString getNotesBytes()
Optional. Standard free-form notes captured at manual logging.
string notes = 14 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
ByteString |
The bytes for notes.
|
getParserForType()
public Parser<Exercise> getParserForType()
Overrides
getSerializedSize()
public int getSerializedSize()
| Returns |
| Type |
Description |
int |
|
Overrides
getSplitSummaries(int index)
public Exercise.SplitSummary getSplitSummaries(int index)
Optional. Laps or splits recorded within an exercise.
Laps could be split based on distance or other criteria (duration, etc.)
Laps should not be overlapping with each other.
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary split_summaries = 9 [(.google.api.field_behavior) = OPTIONAL];
| Parameter |
| Name |
Description |
index |
int
|
getSplitSummariesCount()
public int getSplitSummariesCount()
Optional. Laps or splits recorded within an exercise.
Laps could be split based on distance or other criteria (duration, etc.)
Laps should not be overlapping with each other.
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary split_summaries = 9 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
int |
|
getSplitSummariesList()
public List<Exercise.SplitSummary> getSplitSummariesList()
Optional. Laps or splits recorded within an exercise.
Laps could be split based on distance or other criteria (duration, etc.)
Laps should not be overlapping with each other.
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary split_summaries = 9 [(.google.api.field_behavior) = OPTIONAL];
getSplitSummariesOrBuilder(int index)
public Exercise.SplitSummaryOrBuilder getSplitSummariesOrBuilder(int index)
Optional. Laps or splits recorded within an exercise.
Laps could be split based on distance or other criteria (duration, etc.)
Laps should not be overlapping with each other.
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary split_summaries = 9 [(.google.api.field_behavior) = OPTIONAL];
| Parameter |
| Name |
Description |
index |
int
|
getSplitSummariesOrBuilderList()
public List<? extends Exercise.SplitSummaryOrBuilder> getSplitSummariesOrBuilderList()
Optional. Laps or splits recorded within an exercise.
Laps could be split based on distance or other criteria (duration, etc.)
Laps should not be overlapping with each other.
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary split_summaries = 9 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
List<? extends com.google.devicesandservices.health.v4.Exercise.SplitSummaryOrBuilder> |
|
getSplits(int index)
public Exercise.SplitSummary getSplits(int index)
Optional. The default split is 1 km or 1 mile.
- if the movement distance is less than the default,
then there are no splits
- if the movement distance is greater than or equal to the
default,
then we have splits
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary splits = 8 [(.google.api.field_behavior) = OPTIONAL];
| Parameter |
| Name |
Description |
index |
int
|
getSplitsCount()
public int getSplitsCount()
Optional. The default split is 1 km or 1 mile.
- if the movement distance is less than the default,
then there are no splits
- if the movement distance is greater than or equal to the
default,
then we have splits
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary splits = 8 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
int |
|
getSplitsList()
public List<Exercise.SplitSummary> getSplitsList()
Optional. The default split is 1 km or 1 mile.
- if the movement distance is less than the default,
then there are no splits
- if the movement distance is greater than or equal to the
default,
then we have splits
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary splits = 8 [(.google.api.field_behavior) = OPTIONAL];
getSplitsOrBuilder(int index)
public Exercise.SplitSummaryOrBuilder getSplitsOrBuilder(int index)
Optional. The default split is 1 km or 1 mile.
- if the movement distance is less than the default,
then there are no splits
- if the movement distance is greater than or equal to the
default,
then we have splits
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary splits = 8 [(.google.api.field_behavior) = OPTIONAL];
| Parameter |
| Name |
Description |
index |
int
|
getSplitsOrBuilderList()
public List<? extends Exercise.SplitSummaryOrBuilder> getSplitsOrBuilderList()
Optional. The default split is 1 km or 1 mile.
- if the movement distance is less than the default,
then there are no splits
- if the movement distance is greater than or equal to the
default,
then we have splits
repeated .google.devicesandservices.health.v4.Exercise.SplitSummary splits = 8 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
List<? extends com.google.devicesandservices.health.v4.Exercise.SplitSummaryOrBuilder> |
|
getUpdateTime()
public Timestamp getUpdateTime()
Output only. This is the timestamp of the last update to the exercise.
.google.protobuf.Timestamp update_time = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
Timestamp |
The updateTime.
|
getUpdateTimeOrBuilder()
public TimestampOrBuilder getUpdateTimeOrBuilder()
Output only. This is the timestamp of the last update to the exercise.
.google.protobuf.Timestamp update_time = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];
hasActiveDuration()
public boolean hasActiveDuration()
Optional. Duration excluding pauses.
.google.protobuf.Duration active_duration = 13 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
boolean |
Whether the activeDuration field is set.
|
hasCreateTime()
public boolean hasCreateTime()
Output only. Represents the timestamp of the creation of the exercise.
.google.protobuf.Timestamp create_time = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
boolean |
Whether the createTime field is set.
|
public boolean hasExerciseMetadata()
Optional. Additional exercise metadata.
.google.devicesandservices.health.v4.Exercise.ExerciseMetadata exercise_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];
| Returns |
| Type |
Description |
boolean |
Whether the exerciseMetadata field is set.
|
hasInterval()
public boolean hasInterval()
Required. Observed exercise interval
.google.devicesandservices.health.v4.SessionTimeInterval interval = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns |
| Type |
Description |
boolean |
Whether the interval field is set.
|
hasMetricsSummary()
public boolean hasMetricsSummary()
Required. Summary metrics for this exercise
( )
.google.devicesandservices.health.v4.MetricsSummary metrics_summary = 10 [(.google.api.field_behavior) = REQUIRED];
| Returns |
| Type |
Description |
boolean |
Whether the metricsSummary field is set.
|
hasUpdateTime()
public boolean hasUpdateTime()
Output only. This is the timestamp of the last update to the exercise.
.google.protobuf.Timestamp update_time = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
boolean |
Whether the updateTime field is set.
|
hashCode()
| Returns |
| Type |
Description |
int |
|
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public Exercise.Builder newBuilderForType()
newBuilderForType(AbstractMessage.BuilderParent parent)
protected Exercise.Builder newBuilderForType(AbstractMessage.BuilderParent parent)
Overrides
toBuilder()
public Exercise.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides