docs/doc/reference/com/google/android/exoplayer2/ui/AdViewProvider.html
Package com.google.android.exoplayer2.ui
PlayerView, StyledPlayerView[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")public interfaceAdViewProvider
Deprecated. com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.
Provides information about views for the ad playback UI.
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| default List<AdOverlayInfo> | getAdOverlayInfos() |
Deprecated.
Returns a list of AdOverlayInfo instances describing views that are on top of the ad view group, but that are essential for controlling playback and should be excluded from ad viewability measurements.
|
| ViewGroup | getAdViewGroup() |
Deprecated.
Returns the ViewGroup on top of the player that will show any ad UI, or null if playing audio-only ads.
|
-
@Nullable[ViewGroup](https://developer.android.com/reference/android/view/ViewGroup.html "class or interface in android.view")getAdViewGroup()
Deprecated.
Returns the ViewGroup on top of the player that will show any ad UI, or null if playing audio-only ads. Any views on top of the returned view group must be described by AdOverlayInfos returned by getAdOverlayInfos(), for accurate viewability measurement.
-
default[List](https://developer.android.com/reference/java/util/List.html "class or interface in java.util")<[AdOverlayInfo](AdOverlayInfo.html "class in com.google.android.exoplayer2.ui")> getAdOverlayInfos()
Deprecated.
Returns a list of AdOverlayInfo instances describing views that are on top of the ad view group, but that are essential for controlling playback and should be excluded from ad viewability measurements.
Each view must be either a fully transparent overlay (for capturing touch events), or a small piece of transient UI that is essential to the user experience of playback (such as a button to pause/resume playback or a transient full-screen or cast button). For more information see the documentation for your ads loader.