# AudioFocusManager.PlayerControl

Artifact: [androidx.media3:media3-common](https://developer.android.com/jetpack/androidx/releases/media3) [View Source](https://cs.android.com/search?q=file:androidx/media3/common/audio/AudioFocusManager.java+class:androidx.media3.common.audio.AudioFocusManager.PlayerControl)

*** ** * ** ***


```
public interface AudioFocusManager.PlayerControl
```

<br />

*** ** * ** ***

Interface to allow AudioFocusManager to give commands to a player.

## Summary

| ### Public methods |
|---|---|
| `abstract void` | `https://developer.android.com/reference/androidx/media3/common/audio/AudioFocusManager.PlayerControl#executePlayerCommand(int)(@https://developer.android.com/reference/androidx/media3/common/audio/AudioFocusManager.PlayerCommand int playerCommand)` Called when a command must be executed on the player. |
| `abstract void` | `https://developer.android.com/reference/androidx/media3/common/audio/AudioFocusManager.PlayerControl#setVolumeMultiplier(float)(float volumeMultiplier)` Called when the volume multiplier on the player should be changed. |

## Public methods

### executePlayerCommand

```
abstract void executePlayerCommand(@AudioFocusManager.PlayerCommand int playerCommand)
```

Called when a command must be executed on the player.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/media3/common/audio/AudioFocusManager.PlayerCommand int playerCommand` | The command that must be executed. |

### setVolumeMultiplier

```
abstract void setVolumeMultiplier(float volumeMultiplier)
```

Called when the volume multiplier on the player should be changed.

| Parameters |
|---|---|
| `float volumeMultiplier` | The new volume multiplier. |