Add nullness annotations to Representation

#fixit

PiperOrigin-RevId: 559690973
This commit is contained in:
rohks 2023-08-24 02:35:15 -07:00 committed by Copybara-Service
parent 5276f797e5
commit 80495ddf9c
2 changed files with 4 additions and 2 deletions

View file

@ -63,7 +63,7 @@ public abstract class Representation {
/** Supplemental properties in the adaptation set. May be empty. */
public final List<Descriptor> supplementalProperties;
private final RangedUri initializationUri;
@Nullable private final RangedUri initializationUri;
/**
* Constructs a new instance.

View file

@ -29,6 +29,7 @@ import com.google.common.math.BigIntegerMath;
import java.math.BigInteger;
import java.math.RoundingMode;
import java.util.List;
import org.checkerframework.checker.initialization.qual.UnderInitialization;
/** An approximate representation of a SegmentBase manifest element. */
@UnstableApi
@ -60,7 +61,8 @@ public abstract class SegmentBase {
* @return A {@link RangedUri} defining the location of the initialization data, or null.
*/
@Nullable
public RangedUri getInitialization(Representation representation) {
public RangedUri getInitialization(
@UnderInitialization(Representation.class) Representation representation) {
return initialization;
}