ExerciseCapabilities

public data final class ExerciseCapabilities


A place holder class that represents the capabilities of the androidx.health.services.client.ExerciseClient on the device.

Summary

Public fields

final @NonNull Set<@NonNull ExerciseType>

Returns the set of ExerciseType s that support auto pause and resume on this device.

final @NonNull Set<@NonNull ExerciseType>

Set of supported ExerciseType s on this device.

final @NonNull Map<@NonNull ExerciseType, @NonNull ExerciseTypeCapabilities>

Mapping for each supported ExerciseType to its ExerciseTypeCapabilities on this device.

Public constructors

Public methods

int
final @NonNull ExerciseTypeCapabilities

Returns the supported ExerciseTypeCapabilities for a requested ExerciseType.

void
writeToParcel(@NonNull Parcel dest, int flags)

Public fields

autoPauseAndResumeEnabledExercises

@NonNull
public final @NonNull Set<@NonNull ExerciseTypeautoPauseAndResumeEnabledExercises

Returns the set of ExerciseType s that support auto pause and resume on this device.

supportedExerciseTypes

@NonNull
public final @NonNull Set<@NonNull ExerciseTypesupportedExerciseTypes

Set of supported ExerciseType s on this device.

typeToCapabilities

@NonNull
public final @NonNull Map<@NonNull ExerciseType, @NonNull ExerciseTypeCapabilitiestypeToCapabilities

Mapping for each supported ExerciseType to its ExerciseTypeCapabilities on this device.

Public constructors

ExerciseCapabilities

public final ExerciseCapabilities(
    @NonNull Map<@NonNull ExerciseType, @NonNull ExerciseTypeCapabilities> typeToCapabilities
)

Public methods

describeContents

@NonNull
public int describeContents()

getExerciseTypeCapabilities

@NonNull
public final ExerciseTypeCapabilities getExerciseTypeCapabilities(@NonNull ExerciseType exercise)

Returns the supported ExerciseTypeCapabilities for a requested ExerciseType.

Throws
kotlin.IllegalArgumentException

if the exercise is not supported

writeToParcel

@NonNull
public void writeToParcel(@NonNull Parcel dest, int flags)