PlannedExerciseSessionRecord


public final class PlannedExerciseSessionRecord
extends IntervalRecord

java.lang.Object
   ↳ android.health.connect.datatypes.Record
     ↳ android.health.connect.datatypes.IntervalRecord
       ↳ android.health.connect.datatypes.PlannedExerciseSessionRecord


Captures a planned exercise session, also commonly referred to as a training plan.

Each record contains a start time, end time, an exercise type and a list of PlannedExerciseBlock which describe the details of the planned session. The start and end times may be in the future.

Summary

Nested classes

class PlannedExerciseSessionRecord.Builder

Builder class for PlannedExerciseSessionRecord

Public methods

boolean equals(Object o)

Indicates whether some other object is "equal to" this one.

List<PlannedExerciseBlock> getBlocks()

Returns the exercise blocks for this step.

String getCompletedExerciseSessionId()

Returns the id of exercise session that completed this planned session.

Duration getDuration()

Returns the expected duration of the planned session.

int getExerciseType()

Returns the exercise type of this planned session.

CharSequence getNotes()

Returns notes for this planned session.

LocalDate getStartDate()

Returns the start date of the planned session.

CharSequence getTitle()

Returns title of this planned session.

boolean hasExplicitTime()

Returns whether this planned session has an explicit time.

int hashCode()

Returns a hash code value for the object.

Inherited methods

Public methods

equals

public boolean equals (Object o)

Indicates whether some other object is "equal to" this one.

Parameters
o Object: This value may be null.

Returns
boolean true if this object is the same as the obj

getBlocks

public List<PlannedExerciseBlock> getBlocks ()

Returns the exercise blocks for this step.

Returns
List<PlannedExerciseBlock> An unmodifiable list of PlannedExerciseBlock. This value cannot be null.

getCompletedExerciseSessionId

public String getCompletedExerciseSessionId ()

Returns the id of exercise session that completed this planned session. Returns null if none exists.

Returns
String

getDuration

public Duration getDuration ()

Returns the expected duration of the planned session.

Returns
Duration This value cannot be null.

getExerciseType

public int getExerciseType ()

Returns the exercise type of this planned session.

Returns
int Value is ExerciseSessionType.EXERCISE_SESSION_TYPE_UNKNOWN, ExerciseSessionType.EXERCISE_SESSION_TYPE_BADMINTON, ExerciseSessionType.EXERCISE_SESSION_TYPE_BASEBALL, ExerciseSessionType.EXERCISE_SESSION_TYPE_BASKETBALL, ExerciseSessionType.EXERCISE_SESSION_TYPE_BIKING, ExerciseSessionType.EXERCISE_SESSION_TYPE_BIKING_STATIONARY, ExerciseSessionType.EXERCISE_SESSION_TYPE_BOOT_CAMP, ExerciseSessionType.EXERCISE_SESSION_TYPE_BOXING, ExerciseSessionType.EXERCISE_SESSION_TYPE_CALISTHENICS, ExerciseSessionType.EXERCISE_SESSION_TYPE_CRICKET, ExerciseSessionType.EXERCISE_SESSION_TYPE_DANCING, ExerciseSessionType.EXERCISE_SESSION_TYPE_ELLIPTICAL, ExerciseSessionType.EXERCISE_SESSION_TYPE_EXERCISE_CLASS, ExerciseSessionType.EXERCISE_SESSION_TYPE_FENCING, ExerciseSessionType.EXERCISE_SESSION_TYPE_FOOTBALL_AMERICAN, ExerciseSessionType.EXERCISE_SESSION_TYPE_FOOTBALL_AUSTRALIAN, ExerciseSessionType.EXERCISE_SESSION_TYPE_FRISBEE_DISC, ExerciseSessionType.EXERCISE_SESSION_TYPE_GOLF, ExerciseSessionType.EXERCISE_SESSION_TYPE_GUIDED_BREATHING, ExerciseSessionType.EXERCISE_SESSION_TYPE_GYMNASTICS, ExerciseSessionType.EXERCISE_SESSION_TYPE_HANDBALL, ExerciseSessionType.EXERCISE_SESSION_TYPE_HIGH_INTENSITY_INTERVAL_TRAINING, ExerciseSessionType.EXERCISE_SESSION_TYPE_HIKING, ExerciseSessionType.EXERCISE_SESSION_TYPE_ICE_HOCKEY, ExerciseSessionType.EXERCISE_SESSION_TYPE_ICE_SKATING, ExerciseSessionType.EXERCISE_SESSION_TYPE_MARTIAL_ARTS, ExerciseSessionType.EXERCISE_SESSION_TYPE_PADDLING, ExerciseSessionType.EXERCISE_SESSION_TYPE_PARAGLIDING, ExerciseSessionType.EXERCISE_SESSION_TYPE_PILATES, ExerciseSessionType.EXERCISE_SESSION_TYPE_RACQUETBALL, ExerciseSessionType.EXERCISE_SESSION_TYPE_ROCK_CLIMBING, ExerciseSessionType.EXERCISE_SESSION_TYPE_ROLLER_HOCKEY, ExerciseSessionType.EXERCISE_SESSION_TYPE_ROWING, ExerciseSessionType.EXERCISE_SESSION_TYPE_ROWING_MACHINE, ExerciseSessionType.EXERCISE_SESSION_TYPE_RUGBY, ExerciseSessionType.EXERCISE_SESSION_TYPE_RUNNING, ExerciseSessionType.EXERCISE_SESSION_TYPE_RUNNING_TREADMILL, ExerciseSessionType.EXERCISE_SESSION_TYPE_SAILING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SCUBA_DIVING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SKATING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SKIING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SNOWBOARDING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SNOWSHOEING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SOCCER, ExerciseSessionType.EXERCISE_SESSION_TYPE_SOFTBALL, ExerciseSessionType.EXERCISE_SESSION_TYPE_SQUASH, ExerciseSessionType.EXERCISE_SESSION_TYPE_STAIR_CLIMBING, ExerciseSessionType.EXERCISE_SESSION_TYPE_STAIR_CLIMBING_MACHINE, ExerciseSessionType.EXERCISE_SESSION_TYPE_STRENGTH_TRAINING, ExerciseSessionType.EXERCISE_SESSION_TYPE_STRETCHING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SURFING, ExerciseSessionType.EXERCISE_SESSION_TYPE_SWIMMING_OPEN_WATER, ExerciseSessionType.EXERCISE_SESSION_TYPE_SWIMMING_POOL, ExerciseSessionType.EXERCISE_SESSION_TYPE_TABLE_TENNIS, ExerciseSessionType.EXERCISE_SESSION_TYPE_TENNIS, ExerciseSessionType.EXERCISE_SESSION_TYPE_VOLLEYBALL, ExerciseSessionType.EXERCISE_SESSION_TYPE_WALKING, ExerciseSessionType.EXERCISE_SESSION_TYPE_WATER_POLO, ExerciseSessionType.EXERCISE_SESSION_TYPE_WEIGHTLIFTING, ExerciseSessionType.EXERCISE_SESSION_TYPE_WHEELCHAIR, ExerciseSessionType.EXERCISE_SESSION_TYPE_OTHER_WORKOUT, or ExerciseSessionType.EXERCISE_SESSION_TYPE_YOGA

getNotes

public CharSequence getNotes ()

Returns notes for this planned session. Returns null if it doesn't have notes.

Returns
CharSequence

getStartDate

public LocalDate getStartDate ()

Returns the start date of the planned session.

Returns
LocalDate This value cannot be null.

getTitle

public CharSequence getTitle ()

Returns title of this planned session. Returns null if it doesn't have a title.

Returns
CharSequence

hasExplicitTime

public boolean hasExplicitTime ()

Returns whether this planned session has an explicit time. If only a date was provided this will be false.

Returns
boolean

hashCode

public int hashCode ()

Returns a hash code value for the object.

Returns
int a hash code value for this object.