mirror of
https://github.com/samsonjs/media.git
synced 2026-04-27 15:07:40 +00:00
Fix incorrect @IntRange
PiperOrigin-RevId: 397753634
This commit is contained in:
parent
9666fbdda6
commit
7d524d6d6f
1 changed files with 3 additions and 2 deletions
|
|
@ -118,9 +118,10 @@ public final class AdPlaybackState implements Bundleable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the index of the next ad in the ad group that should be played after playing {@code
|
* Returns the index of the next ad in the ad group that should be played after playing {@code
|
||||||
* lastPlayedAdIndex}, or {@link #count} if no later ads should be played.
|
* lastPlayedAdIndex}, or {@link #count} if no later ads should be played. If no ads have been
|
||||||
|
* played, pass -1 to get the index of the first ad to play.
|
||||||
*/
|
*/
|
||||||
public int getNextAdIndexToPlay(@IntRange(from = 0) int lastPlayedAdIndex) {
|
public int getNextAdIndexToPlay(@IntRange(from = -1) int lastPlayedAdIndex) {
|
||||||
int nextAdIndexToPlay = lastPlayedAdIndex + 1;
|
int nextAdIndexToPlay = lastPlayedAdIndex + 1;
|
||||||
while (nextAdIndexToPlay < states.length) {
|
while (nextAdIndexToPlay < states.length) {
|
||||||
if (isServerSideInserted
|
if (isServerSideInserted
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue