diff --git a/library/core/src/main/java/com/google/android/exoplayer2/decoder/SimpleDecoder.java b/library/common/src/main/java/com/google/android/exoplayer2/decoder/SimpleDecoder.java similarity index 98% rename from library/core/src/main/java/com/google/android/exoplayer2/decoder/SimpleDecoder.java rename to library/common/src/main/java/com/google/android/exoplayer2/decoder/SimpleDecoder.java index 896fb06568..1886cdf9f4 100644 --- a/library/core/src/main/java/com/google/android/exoplayer2/decoder/SimpleDecoder.java +++ b/library/common/src/main/java/com/google/android/exoplayer2/decoder/SimpleDecoder.java @@ -40,9 +40,9 @@ public abstract class SimpleDecoder< private int availableInputBufferCount; private int availableOutputBufferCount; - private I dequeuedInputBuffer; + @Nullable private I dequeuedInputBuffer; - private E exception; + @Nullable private E exception; private boolean flushed; private boolean released; private int skippedOutputBufferCount; @@ -51,6 +51,7 @@ public abstract class SimpleDecoder< * @param inputBuffers An array of nulls that will be used to store references to input buffers. * @param outputBuffers An array of nulls that will be used to store references to output buffers. */ + @SuppressWarnings("nullness:method.invocation") protected SimpleDecoder(I[] inputBuffers, O[] outputBuffers) { lock = new Object(); queuedInputBuffers = new ArrayDeque<>(); @@ -178,6 +179,7 @@ public abstract class SimpleDecoder< * @throws E The decode exception. */ private void maybeThrowException() throws E { + @Nullable E exception = this.exception; if (exception != null) { throw exception; } diff --git a/library/core/src/main/java/com/google/android/exoplayer2/decoder/SimpleOutputBuffer.java b/library/common/src/main/java/com/google/android/exoplayer2/decoder/SimpleOutputBuffer.java similarity index 100% rename from library/core/src/main/java/com/google/android/exoplayer2/decoder/SimpleOutputBuffer.java rename to library/common/src/main/java/com/google/android/exoplayer2/decoder/SimpleOutputBuffer.java diff --git a/library/core/src/main/java/com/google/android/exoplayer2/drm/DecryptionException.java b/library/common/src/main/java/com/google/android/exoplayer2/drm/DecryptionException.java similarity index 100% rename from library/core/src/main/java/com/google/android/exoplayer2/drm/DecryptionException.java rename to library/common/src/main/java/com/google/android/exoplayer2/drm/DecryptionException.java diff --git a/library/core/src/main/java/com/google/android/exoplayer2/util/LibraryLoader.java b/library/common/src/main/java/com/google/android/exoplayer2/util/LibraryLoader.java similarity index 100% rename from library/core/src/main/java/com/google/android/exoplayer2/util/LibraryLoader.java rename to library/common/src/main/java/com/google/android/exoplayer2/util/LibraryLoader.java