# Vo2MaxRecord

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

*** ** * ** ***


```
class Vo2MaxRecord : Record
```

<br />

*** ** * ** ***

Capture user's VO2 max score and optionally the measurement method.

## Summary

| ### Constants |
|---|---|
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#MEASUREMENT_METHOD_COOPER_TEST() = 3` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#MEASUREMENT_METHOD_HEART_RATE_RATIO() = 2` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#MEASUREMENT_METHOD_METABOLIC_CART() = 1` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#MEASUREMENT_METHOD_MULTISTAGE_FITNESS_TEST() = 4` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#MEASUREMENT_METHOD_OTHER() = 0` |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#MEASUREMENT_METHOD_ROCKPORT_FITNESS_TEST() = 5` |

| ### Public constructors |
|---|
| `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#Vo2MaxRecord(java.time.Instant,java.time.ZoneOffset,androidx.health.connect.client.records.metadata.Metadata,kotlin.Double,kotlin.Int)( time: https://developer.android.com/reference/java/time/Instant.html, zoneOffset: https://developer.android.com/reference/java/time/ZoneOffset.html?, metadata: https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/metadata/Metadata, vo2MillilitersPerMinuteKilogram: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html, measurementMethod: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html )` |

| ### Public functions |
|---|---|
| `open operator https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#equals(kotlin.Any)(other: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html?)` |
| `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#hashCode()()` |
| `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#toString()()` |

| ### Public properties |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#measurementMethod()` VO2 max measurement method. |
| `open https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/metadata/Metadata` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#metadata()` Set of common metadata associated with the written record. |
| `open https://developer.android.com/reference/java/time/Instant.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#time()` Time the record happened. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#vo2MillilitersPerMinuteKilogram()` Maximal aerobic capacity (VO2 max) in milliliters. |
| `open https://developer.android.com/reference/java/time/ZoneOffset.html?` | `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord#zoneOffset()` User experienced zone offset at `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/InstantaneousRecord#time()`, or null if unknown. |

## Constants

### MEASUREMENT_METHOD_COOPER_TEST

```
const val MEASUREMENT_METHOD_COOPER_TEST = 3: Int
```

### MEASUREMENT_METHOD_HEART_RATE_RATIO

```
const val MEASUREMENT_METHOD_HEART_RATE_RATIO = 2: Int
```

### MEASUREMENT_METHOD_METABOLIC_CART

```
const val MEASUREMENT_METHOD_METABOLIC_CART = 1: Int
```

### MEASUREMENT_METHOD_MULTISTAGE_FITNESS_TEST

```
const val MEASUREMENT_METHOD_MULTISTAGE_FITNESS_TEST = 4: Int
```

### MEASUREMENT_METHOD_OTHER

```
const val MEASUREMENT_METHOD_OTHER = 0: Int
```

### MEASUREMENT_METHOD_ROCKPORT_FITNESS_TEST

```
const val MEASUREMENT_METHOD_ROCKPORT_FITNESS_TEST = 5: Int
```

## Public constructors

### Vo2MaxRecord

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

```
Vo2MaxRecord(
    time: Instant,
    zoneOffset: ZoneOffset?,
    metadata: Metadata,
    vo2MillilitersPerMinuteKilogram: Double,
    measurementMethod: Int = MEASUREMENT_METHOD_OTHER
)
```

## Public functions

### equals

```
open operator fun equals(other: Any?): Boolean
```

### hashCode

```
open fun hashCode(): Int
```

### toString

```
open fun toString(): String
```

## Public properties

### measurementMethod

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

```
val measurementMethod: Int
```

VO2 max measurement method. Optional field. Allowed values: `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord.MeasurementMethod`.

Value is one of the following:

- `0`
- `1`
- `2`
- `3`
- `4`
- `5`

<br />

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/Vo2MaxRecord.MeasurementMethod` |   |

### metadata

```
open val metadata: Metadata
```

Set of common metadata associated with the written record.

### time

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

```
open val time: Instant
```

Time the record happened.

### vo2MillilitersPerMinuteKilogram

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

```
val vo2MillilitersPerMinuteKilogram: Double
```

Maximal aerobic capacity (VO2 max) in milliliters. Required field. Valid range: 0-100.

### zoneOffset

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

```
open val zoneOffset: ZoneOffset?
```

User experienced zone offset at `https://developer.android.com/reference/kotlin/androidx/health/connect/client/records/InstantaneousRecord#time()`, or null if unknown. Providing these will help history aggregations results stay consistent should user travel. Queries with user experienced time filters will assume system current zone offset if the information is absent.