# HlsTrackMetadataEntry.VariantInfo

Artifact: [androidx.media3:media3-exoplayer-hls](https://developer.android.com/jetpack/androidx/releases/media3) [View Source](https://cs.android.com/search?q=file:androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.java+class:androidx.media3.exoplayer.hls.HlsTrackMetadataEntry.VariantInfo)

*** ** * ** ***


```
public final class HlsTrackMetadataEntry.VariantInfo
```

<br />

*** ** * ** ***

Holds attributes defined in an EXT-X-STREAM-INF tag.

## Summary

| ### Public fields |
|---|---|
| `final @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#audioGroupId()` The AUDIO value as defined in the EXT-X-STREAM-INF tag, or null if the AUDIO attribute is not present. |
| `final int` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#averageBitrate()` The average bitrate as declared by the AVERAGE-BANDWIDTH attribute of the EXT-X-STREAM-INF tag, or `https://developer.android.com/reference/androidx/media3/common/Format#NO_VALUE()` if the attribute is not declared. |
| `final @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#captionGroupId()` The CLOSED-CAPTIONS value as defined in the EXT-X-STREAM-INF tag, or null if the CLOSED-CAPTIONS attribute is not present. |
| `final int` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#peakBitrate()` The peak bitrate as declared by the BANDWIDTH attribute of the EXT-X-STREAM-INF tag. |
| `final @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#subtitleGroupId()` The SUBTITLES value as defined in the EXT-X-STREAM-INF tag, or null if the SUBTITLES attribute is not present. |
| `final @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#videoGroupId()` The VIDEO value as defined in the EXT-X-STREAM-INF tag, or null if the VIDEO attribute is not present. |

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#VariantInfo(int,int,java.lang.String,java.lang.String,java.lang.String,java.lang.String)( int averageBitrate, int peakBitrate, @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html videoGroupId, @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html audioGroupId, @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html subtitleGroupId, @https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html captionGroupId )` Creates an instance. |

| ### Public methods |
|---|---|
| `boolean` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#equals(java.lang.Object)(@https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/Object.html other)` |
| `int` | `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#hashCode()()` |

## Public fields

### audioGroupId

```
public final @Nullable String audioGroupId
```

The AUDIO value as defined in the EXT-X-STREAM-INF tag, or null if the AUDIO attribute is not present.

### averageBitrate

```
public final int averageBitrate
```

The average bitrate as declared by the AVERAGE-BANDWIDTH attribute of the EXT-X-STREAM-INF tag, or `https://developer.android.com/reference/androidx/media3/common/Format#NO_VALUE()` if the attribute is not declared.

### captionGroupId

```
public final @Nullable String captionGroupId
```

The CLOSED-CAPTIONS value as defined in the EXT-X-STREAM-INF tag, or null if the CLOSED-CAPTIONS attribute is not present.

### peakBitrate

```
public final int peakBitrate
```

The peak bitrate as declared by the BANDWIDTH attribute of the EXT-X-STREAM-INF tag.

### subtitleGroupId

```
public final @Nullable String subtitleGroupId
```

The SUBTITLES value as defined in the EXT-X-STREAM-INF tag, or null if the SUBTITLES attribute is not present.

### videoGroupId

```
public final @Nullable String videoGroupId
```

The VIDEO value as defined in the EXT-X-STREAM-INF tag, or null if the VIDEO attribute is not present.

## Public constructors

### VariantInfo

```
public VariantInfo(
    int averageBitrate,
    int peakBitrate,
    @Nullable String videoGroupId,
    @Nullable String audioGroupId,
    @Nullable String subtitleGroupId,
    @Nullable String captionGroupId
)
```

Creates an instance.

| Parameters |
|---|---|
| `int averageBitrate` | See `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#averageBitrate()`. |
| `int peakBitrate` | See `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#peakBitrate()`. |
| `@https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html videoGroupId` | See `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#videoGroupId()`. |
| `@https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html audioGroupId` | See `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#audioGroupId()`. |
| `@https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html subtitleGroupId` | See `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#subtitleGroupId()`. |
| `@https://developer.android.com/reference/androidx/annotation/Nullable https://developer.android.com/reference/java/lang/String.html captionGroupId` | See `https://developer.android.com/reference/androidx/media3/exoplayer/hls/HlsTrackMetadataEntry.VariantInfo#captionGroupId()`. |

## Public methods

### equals

```
public boolean equals(@Nullable Object other)
```

### hashCode

```
public int hashCode()
```