Loading api/current.txt +2 −0 Original line number Diff line number Diff line Loading @@ -14673,6 +14673,8 @@ package android.graphics { method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull android.content.res.Resources, int); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull android.content.ContentResolver, @NonNull android.net.Uri); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull android.content.res.AssetManager, @NonNull String); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull byte[], int, int) throws java.lang.ArrayIndexOutOfBoundsException; method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull byte[]); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull java.nio.ByteBuffer); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull java.io.File); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull java.util.concurrent.Callable<android.content.res.AssetFileDescriptor>); graphics/java/android/graphics/ImageDecoder.java +19 −3 Original line number Diff line number Diff line Loading @@ -939,6 +939,12 @@ public final class ImageDecoder implements AutoCloseable { /** * Create a new {@link Source Source} from a byte array. * * <p>Note: If this {@code Source} is passed to {@link #decodeDrawable decodeDrawable}, * and the encoded image is animated, the returned {@link AnimatedImageDrawable} * will continue reading from {@code data}, so its contents must not * be modified, even after the {@code AnimatedImageDrawable} is returned. * {@code data}'s contents should never be modified during decode.</p> * * @param data byte array of compressed image data. * @param offset offset into data for where the decoder should begin * parsing. Loading @@ -949,7 +955,6 @@ public final class ImageDecoder implements AutoCloseable { * @throws NullPointerException if data is null. * @throws ArrayIndexOutOfBoundsException if offset and length are * not within data. * @hide */ @AnyThread @NonNull Loading @@ -967,8 +972,19 @@ public final class ImageDecoder implements AutoCloseable { } /** * See {@link #createSource(byte[], int, int). * @hide * Create a new {@link Source Source} from a byte array. * * <p>Note: If this {@code Source} is passed to {@link #decodeDrawable decodeDrawable}, * and the encoded image is animated, the returned {@link AnimatedImageDrawable} * will continue reading from {@code data}, so its contents must not * be modified, even after the {@code AnimatedImageDrawable} is returned. * {@code data}'s contents should never be modified during decode.</p> * * @param data byte array of compressed image data. * @return a new Source object, which can be passed to * {@link #decodeDrawable decodeDrawable} or * {@link #decodeBitmap decodeBitmap}. * @throws NullPointerException if data is null. */ @AnyThread @NonNull Loading Loading
api/current.txt +2 −0 Original line number Diff line number Diff line Loading @@ -14673,6 +14673,8 @@ package android.graphics { method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull android.content.res.Resources, int); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull android.content.ContentResolver, @NonNull android.net.Uri); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull android.content.res.AssetManager, @NonNull String); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull byte[], int, int) throws java.lang.ArrayIndexOutOfBoundsException; method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull byte[]); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull java.nio.ByteBuffer); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull java.io.File); method @AnyThread @NonNull public static android.graphics.ImageDecoder.Source createSource(@NonNull java.util.concurrent.Callable<android.content.res.AssetFileDescriptor>);
graphics/java/android/graphics/ImageDecoder.java +19 −3 Original line number Diff line number Diff line Loading @@ -939,6 +939,12 @@ public final class ImageDecoder implements AutoCloseable { /** * Create a new {@link Source Source} from a byte array. * * <p>Note: If this {@code Source} is passed to {@link #decodeDrawable decodeDrawable}, * and the encoded image is animated, the returned {@link AnimatedImageDrawable} * will continue reading from {@code data}, so its contents must not * be modified, even after the {@code AnimatedImageDrawable} is returned. * {@code data}'s contents should never be modified during decode.</p> * * @param data byte array of compressed image data. * @param offset offset into data for where the decoder should begin * parsing. Loading @@ -949,7 +955,6 @@ public final class ImageDecoder implements AutoCloseable { * @throws NullPointerException if data is null. * @throws ArrayIndexOutOfBoundsException if offset and length are * not within data. * @hide */ @AnyThread @NonNull Loading @@ -967,8 +972,19 @@ public final class ImageDecoder implements AutoCloseable { } /** * See {@link #createSource(byte[], int, int). * @hide * Create a new {@link Source Source} from a byte array. * * <p>Note: If this {@code Source} is passed to {@link #decodeDrawable decodeDrawable}, * and the encoded image is animated, the returned {@link AnimatedImageDrawable} * will continue reading from {@code data}, so its contents must not * be modified, even after the {@code AnimatedImageDrawable} is returned. * {@code data}'s contents should never be modified during decode.</p> * * @param data byte array of compressed image data. * @return a new Source object, which can be passed to * {@link #decodeDrawable decodeDrawable} or * {@link #decodeBitmap decodeBitmap}. * @throws NullPointerException if data is null. */ @AnyThread @NonNull Loading