# ExerciseLapSummary

Artifact: [androidx.health:health-services-client](https://developer.android.com/jetpack/androidx/releases/health) [View Source](https://cs.android.com/search?q=file:androidx/health/services/client/data/ExerciseLapSummary.kt+class:androidx.health.services.client.data.ExerciseLapSummary) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/health#1.0.0)

*** ** * ** ***


```
public final class ExerciseLapSummary
```

<br />

*** ** * ** ***

Describes a completed exercise lap.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#ExerciseLapSummary(kotlin.Int,java.time.Instant,java.time.Instant,java.time.Duration,androidx.health.services.client.data.DataPointContainer)( int lapCount, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/time/Instant.html startTime, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/time/Instant.html endTime, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/time/Duration.html activeDuration, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/health/services/client/data/DataPointContainer lapMetrics )` |

| ### Public methods |
|---|---|
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/time/Duration.html` | `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#getActiveDuration()()` Returns the total elapsed time for which the exercise has been active during this lap, i.e. started but not paused. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/time/Instant.html` | `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#getEndTime()()` Returns the time at which the lap has ended. |
| `final int` | `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#getLapCount()()` Returns the lap count of this summary. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/health/services/client/data/DataPointContainer` | `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#getLapMetrics()()` Returns the `https://developer.android.com/reference/androidx/health/services/client/data/DataPoint`s for each metric keyed by `https://developer.android.com/reference/androidx/health/services/client/data/DataType` tracked between `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#(kotlin.Int,java.time.Instant,java.time.Instant,java.time.Duration,androidx.health.services.client.data.DataPointContainer)` and `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#(kotlin.Int,java.time.Instant,java.time.Instant,java.time.Duration,androidx.health.services.client.data.DataPointContainer)` i.e. during the duration of this lap. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/time/Instant.html` | `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#getStartTime()()` Returns the time at which the lap has started. |
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#toString()()` |

## Public constructors

### ExerciseLapSummary

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/health#1.0.0)

```
public ExerciseLapSummary(
    int lapCount,
    @NonNull Instant startTime,
    @NonNull Instant endTime,
    @NonNull Duration activeDuration,
    @NonNull DataPointContainer lapMetrics
)
```

## Public methods

### getActiveDuration

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/health#1.0.0)

```
public final @NonNull Duration getActiveDuration()
```

Returns the total elapsed time for which the exercise has been active during this lap, i.e. started but not paused.

### getEndTime

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/health#1.0.0)

```
public final @NonNull Instant getEndTime()
```

Returns the time at which the lap has ended.

### getLapCount

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/health#1.0.0)

```
public final int getLapCount()
```

Returns the lap count of this summary. Lap count starts at 1 for the first lap.

### getLapMetrics

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/health#1.0.0)

```
public final @NonNull DataPointContainer getLapMetrics()
```

Returns the `https://developer.android.com/reference/androidx/health/services/client/data/DataPoint`s for each metric keyed by `https://developer.android.com/reference/androidx/health/services/client/data/DataType` tracked between `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#(kotlin.Int,java.time.Instant,java.time.Instant,java.time.Duration,androidx.health.services.client.data.DataPointContainer)` and `https://developer.android.com/reference/androidx/health/services/client/data/ExerciseLapSummary#(kotlin.Int,java.time.Instant,java.time.Instant,java.time.Duration,androidx.health.services.client.data.DataPointContainer)` i.e. during the duration of this lap. This will only contain `https://developer.android.com/reference/androidx/health/services/client/data/AggregateDataType`s calculated over the duration of the lap.

### getStartTime

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/health#1.0.0)

```
public final @NonNull Instant getStartTime()
```

Returns the time at which the lap has started.

### toString

```
public @NonNull String toString()
```