mirror of
https://github.com/androidx/media.git
synced 2025-05-16 12:09:50 +08:00
Suppress warnings emitted by Checker Framework version 2.11.1
More information: https://docs.google.com/document/d/16tpK6aXqN68PvTyvt4siM-m7f0NXi_8xEeitLDzr8xY/edit?usp=sharing Tested: TAP train for global presubmit queue http://test/OCL:278152710:BASE:278144052:1572760370662:22459c12 PiperOrigin-RevId: 278241536
This commit is contained in:
parent
7e070683a3
commit
880b879e8c
@ -647,6 +647,8 @@ public final class MediaSessionConnector {
|
||||
* @param customActionProviders The custom action providers, or null to remove all existing custom
|
||||
* action providers.
|
||||
*/
|
||||
// incompatible types in assignment.
|
||||
@SuppressWarnings("nullness:assignment.type.incompatible")
|
||||
public void setCustomActionProviders(@Nullable CustomActionProvider... customActionProviders) {
|
||||
this.customActionProviders =
|
||||
customActionProviders == null ? new CustomActionProvider[0] : customActionProviders;
|
||||
|
@ -25,7 +25,10 @@ import java.util.Arrays;
|
||||
* An {@link AudioProcessor} that applies a mapping from input channels onto specified output
|
||||
* channels. This can be used to reorder, duplicate or discard channels.
|
||||
*/
|
||||
/* package */ final class ChannelMappingAudioProcessor extends BaseAudioProcessor {
|
||||
/* package */
|
||||
// the constructor does not initialize fields: pendingOutputChannels, outputChannels
|
||||
@SuppressWarnings("nullness:initialization.fields.uninitialized")
|
||||
final class ChannelMappingAudioProcessor extends BaseAudioProcessor {
|
||||
|
||||
@Nullable private int[] pendingOutputChannels;
|
||||
|
||||
|
@ -326,6 +326,8 @@ public class DefaultDrmSessionManager<T extends ExoMediaCrypto>
|
||||
new DefaultLoadErrorHandlingPolicy(initialDrmRequestRetryCount));
|
||||
}
|
||||
|
||||
// the constructor does not initialize fields: offlineLicenseKeySetId
|
||||
@SuppressWarnings("nullness:initialization.fields.uninitialized")
|
||||
private DefaultDrmSessionManager(
|
||||
UUID uuid,
|
||||
ExoMediaDrm.Provider<T> exoMediaDrmProvider,
|
||||
|
@ -129,6 +129,8 @@ public final class Track {
|
||||
: sampleDescriptionEncryptionBoxes[sampleDescriptionIndex];
|
||||
}
|
||||
|
||||
// incompatible types in argument.
|
||||
@SuppressWarnings("nullness:argument.type.incompatible")
|
||||
public Track copyWithFormat(Format format) {
|
||||
return new Track(
|
||||
id,
|
||||
|
@ -943,6 +943,8 @@ public final class MediaCodecUtil {
|
||||
|
||||
@Nullable private android.media.MediaCodecInfo[] mediaCodecInfos;
|
||||
|
||||
// the constructor does not initialize fields: mediaCodecInfos
|
||||
@SuppressWarnings("nullness:initialization.fields.uninitialized")
|
||||
public MediaCodecListCompatV21(boolean includeSecure, boolean includeTunneling) {
|
||||
codecKind =
|
||||
includeSecure || includeTunneling
|
||||
@ -956,6 +958,8 @@ public final class MediaCodecUtil {
|
||||
return mediaCodecInfos.length;
|
||||
}
|
||||
|
||||
// incompatible types in return.
|
||||
@SuppressWarnings("nullness:return.type.incompatible")
|
||||
@Override
|
||||
public android.media.MediaCodecInfo getCodecInfoAt(int index) {
|
||||
ensureMediaCodecInfosInitialized();
|
||||
|
@ -302,6 +302,8 @@ public final class DefaultDownloadIndex implements WritableDownloadIndex {
|
||||
}
|
||||
}
|
||||
|
||||
// incompatible types in argument.
|
||||
@SuppressWarnings("nullness:argument.type.incompatible")
|
||||
private Cursor getCursor(String selection, @Nullable String[] selectionArgs)
|
||||
throws DatabaseIOException {
|
||||
try {
|
||||
|
@ -383,6 +383,8 @@ import org.checkerframework.checker.nullness.qual.MonotonicNonNull;
|
||||
|
||||
@Nullable private byte[] sampleData;
|
||||
|
||||
// the constructor does not initialize fields: sampleData
|
||||
@SuppressWarnings("nullness:initialization.fields.uninitialized")
|
||||
public SourceLoadable(DataSpec dataSpec, DataSource dataSource) {
|
||||
this.dataSpec = dataSpec;
|
||||
this.dataSource = new StatsDataSource(dataSource);
|
||||
|
@ -609,13 +609,18 @@ public class AdaptiveTrackSelection extends BaseTrackSelection {
|
||||
|
||||
@Nullable private long[][] allocationCheckpoints;
|
||||
|
||||
/* package */ DefaultBandwidthProvider(
|
||||
/* package */
|
||||
// the constructor does not initialize fields: allocationCheckpoints
|
||||
@SuppressWarnings("nullness:initialization.fields.uninitialized")
|
||||
DefaultBandwidthProvider(
|
||||
BandwidthMeter bandwidthMeter, float bandwidthFraction, long reservedBandwidth) {
|
||||
this.bandwidthMeter = bandwidthMeter;
|
||||
this.bandwidthFraction = bandwidthFraction;
|
||||
this.reservedBandwidth = reservedBandwidth;
|
||||
}
|
||||
|
||||
// unboxing a possibly-null reference allocationCheckpoints[nextIndex][0]
|
||||
@SuppressWarnings("nullness:unboxing.of.nullable")
|
||||
@Override
|
||||
public long getAllocatedBandwidth() {
|
||||
long totalBandwidth = (long) (bandwidthMeter.getBitrateEstimate() * bandwidthFraction);
|
||||
|
@ -36,6 +36,8 @@ public final class DataSchemeDataSource extends BaseDataSource {
|
||||
private int endPosition;
|
||||
private int readPosition;
|
||||
|
||||
// the constructor does not initialize fields: data
|
||||
@SuppressWarnings("nullness:initialization.fields.uninitialized")
|
||||
public DataSchemeDataSource() {
|
||||
super(/* isNetwork= */ false);
|
||||
}
|
||||
|
@ -60,6 +60,8 @@ import org.checkerframework.checker.nullness.qual.MonotonicNonNull;
|
||||
|
||||
// Methods called on any thread.
|
||||
|
||||
// the constructor does not initialize fields: lastProjectionData
|
||||
@SuppressWarnings("nullness:initialization.fields.uninitialized")
|
||||
public SceneRenderer() {
|
||||
frameAvailable = new AtomicBoolean();
|
||||
resetRotationAtNextFrame = new AtomicBoolean(true);
|
||||
|
Loading…
x
Reference in New Issue
Block a user