mirror of
https://github.com/androidx/media.git
synced 2025-05-06 15:10:34 +08:00
Fix all FIXME comments.
These are mostly nullability issues. PiperOrigin-RevId: 253537068
This commit is contained in:
parent
feefaacb31
commit
18f1b06a68
@ -544,7 +544,7 @@ public class DefaultDrmSessionManager<T extends ExoMediaCrypto> implements DrmSe
|
||||
@Override
|
||||
public void onEvent(
|
||||
ExoMediaDrm<? extends T> md,
|
||||
byte[] sessionId,
|
||||
@Nullable byte[] sessionId,
|
||||
int event,
|
||||
int extra,
|
||||
@Nullable byte[] data) {
|
||||
|
@ -80,7 +80,7 @@ public interface ExoMediaDrm<T extends ExoMediaCrypto> {
|
||||
*/
|
||||
void onEvent(
|
||||
ExoMediaDrm<? extends T> mediaDrm,
|
||||
byte[] sessionId,
|
||||
@Nullable byte[] sessionId,
|
||||
int event,
|
||||
int extra,
|
||||
@Nullable byte[] data);
|
||||
@ -215,6 +215,7 @@ public interface ExoMediaDrm<T extends ExoMediaCrypto> {
|
||||
throws NotProvisionedException;
|
||||
|
||||
/** @see MediaDrm#provideKeyResponse(byte[], byte[]) */
|
||||
@Nullable
|
||||
byte[] provideKeyResponse(byte[] scope, byte[] response)
|
||||
throws NotProvisionedException, DeniedByServerException;
|
||||
|
||||
|
@ -84,8 +84,6 @@ public final class FrameworkMediaDrm implements ExoMediaDrm<FrameworkMediaCrypto
|
||||
}
|
||||
}
|
||||
|
||||
// FIXME: incompatible types in argument.
|
||||
@SuppressWarnings("nullness:argument.type.incompatible")
|
||||
@Override
|
||||
public void setOnEventListener(
|
||||
final ExoMediaDrm.OnEventListener<? super FrameworkMediaCrypto> listener) {
|
||||
@ -160,8 +158,7 @@ public final class FrameworkMediaDrm implements ExoMediaDrm<FrameworkMediaCrypto
|
||||
return new KeyRequest(requestData, licenseServerUrl);
|
||||
}
|
||||
|
||||
// FIXME: incompatible types in return.
|
||||
@SuppressWarnings("nullness:return.type.incompatible")
|
||||
@Nullable
|
||||
@Override
|
||||
public byte[] provideKeyResponse(byte[] scope, byte[] response)
|
||||
throws NotProvisionedException, DeniedByServerException {
|
||||
|
@ -25,6 +25,7 @@ import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.PersistableBundle;
|
||||
import androidx.annotation.RequiresPermission;
|
||||
import com.google.android.exoplayer2.util.Assertions;
|
||||
import com.google.android.exoplayer2.util.Log;
|
||||
import com.google.android.exoplayer2.util.Util;
|
||||
|
||||
@ -129,9 +130,8 @@ public final class PlatformScheduler implements Scheduler {
|
||||
logd("Requirements are met");
|
||||
String serviceAction = extras.getString(KEY_SERVICE_ACTION);
|
||||
String servicePackage = extras.getString(KEY_SERVICE_PACKAGE);
|
||||
// FIXME: incompatible types in argument.
|
||||
@SuppressWarnings("nullness:argument.type.incompatible")
|
||||
Intent intent = new Intent(serviceAction).setPackage(servicePackage);
|
||||
Intent intent =
|
||||
new Intent(Assertions.checkNotNull(serviceAction)).setPackage(servicePackage);
|
||||
logd("Starting service action: " + serviceAction + " package: " + servicePackage);
|
||||
Util.startForegroundService(this, intent);
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user