Loading core/java/android/database/AbstractCursor.java +18 −4 Original line number Diff line number Diff line Loading @@ -33,11 +33,11 @@ import java.util.List; import java.util.Map; import java.util.Objects; /** * This is an abstract cursor class that handles a lot of the common code * that all cursors need to deal with and is provided for convenience reasons. */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public abstract class AbstractCursor implements CrossProcessCursor { private static final String TAG = "Cursor"; Loading Loading @@ -89,7 +89,7 @@ public abstract class AbstractCursor implements CrossProcessCursor { private Bundle mExtras = Bundle.EMPTY; /** CloseGuard to detect leaked cursor **/ private final CloseGuard mCloseGuard = CloseGuard.get(); private final CloseGuard mCloseGuard; /* -------------------------------------------------------- */ /* These need to be implemented by subclasses */ Loading Loading @@ -184,8 +184,10 @@ public abstract class AbstractCursor implements CrossProcessCursor { mClosed = true; mContentObservable.unregisterAll(); onDeactivateOrClose(); if (mCloseGuard != null) { mCloseGuard.close(); } } /** * This function is called every time the cursor is successfully scrolled Loading Loading @@ -224,8 +226,20 @@ public abstract class AbstractCursor implements CrossProcessCursor { /* Implementation */ public AbstractCursor() { mPos = -1; mCloseGuard = initCloseGuard(); if (mCloseGuard != null) { mCloseGuard.open("AbstractCursor.close"); } } @android.ravenwood.annotation.RavenwoodReplace private CloseGuard initCloseGuard() { return CloseGuard.get(); } private CloseGuard initCloseGuard$ravenwood() { return null; } @Override public final int getPosition() { Loading core/java/android/database/CharArrayBuffer.java +1 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ package android.database; /** * This is used for {@link Cursor#copyStringToBuffer} */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public final class CharArrayBuffer { public CharArrayBuffer(int size) { data = new char[size]; Loading core/java/android/database/ContentObservable.java +1 −0 Original line number Diff line number Diff line Loading @@ -23,6 +23,7 @@ import android.net.Uri; * that provides methods for sending notifications to a list of * {@link ContentObserver} objects. */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public class ContentObservable extends Observable<ContentObserver> { // Even though the generic method defined in Observable would be perfectly // fine on its own, we can't delete this overridden method because it would Loading core/java/android/database/ContentObserver.java +11 −2 Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ import java.util.Collection; * Receives call backs for changes to content. * Must be implemented by objects which are added to a {@link ContentObservable}. */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public abstract class ContentObserver { /** * Starting in {@link android.os.Build.VERSION_CODES#R}, there is a new Loading @@ -49,7 +50,6 @@ public abstract class ContentObserver { @ChangeId @EnabledAfter(targetSdkVersion=android.os.Build.VERSION_CODES.Q) private static final long ADD_CONTENT_OBSERVER_FLAGS = 150939131L; private final Object mLock = new Object(); private Transport mTransport; // guarded by mLock Loading Loading @@ -216,7 +216,7 @@ public abstract class ContentObserver { // There are dozens of people relying on the hidden API inside the // system UID, so hard-code the old behavior for all of them; for // everyone else we gate based on a specific change if (!CompatChanges.isChangeEnabled(ADD_CONTENT_OBSERVER_FLAGS) if (!isChangeEnabledAddContentObserverFlags() || android.os.Process.myUid() == android.os.Process.SYSTEM_UID) { // Deliver userId through argument to preserve hidden API behavior onChange(selfChange, uris, flags, UserHandle.of(userId)); Loading @@ -225,6 +225,15 @@ public abstract class ContentObserver { } } @android.ravenwood.annotation.RavenwoodReplace private static boolean isChangeEnabledAddContentObserverFlags() { return CompatChanges.isChangeEnabled(ADD_CONTENT_OBSERVER_FLAGS); } private static boolean isChangeEnabledAddContentObserverFlags$ravenwood() { return true; } /** * Dispatches a change notification to the observer. * <p> Loading core/java/android/database/Cursor.java +1 −0 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ import java.util.List; * Implementations should subclass {@link AbstractCursor}. * </p> */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public interface Cursor extends Closeable { /* * Values returned by {@link #getType(int)}. Loading Loading
core/java/android/database/AbstractCursor.java +18 −4 Original line number Diff line number Diff line Loading @@ -33,11 +33,11 @@ import java.util.List; import java.util.Map; import java.util.Objects; /** * This is an abstract cursor class that handles a lot of the common code * that all cursors need to deal with and is provided for convenience reasons. */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public abstract class AbstractCursor implements CrossProcessCursor { private static final String TAG = "Cursor"; Loading Loading @@ -89,7 +89,7 @@ public abstract class AbstractCursor implements CrossProcessCursor { private Bundle mExtras = Bundle.EMPTY; /** CloseGuard to detect leaked cursor **/ private final CloseGuard mCloseGuard = CloseGuard.get(); private final CloseGuard mCloseGuard; /* -------------------------------------------------------- */ /* These need to be implemented by subclasses */ Loading Loading @@ -184,8 +184,10 @@ public abstract class AbstractCursor implements CrossProcessCursor { mClosed = true; mContentObservable.unregisterAll(); onDeactivateOrClose(); if (mCloseGuard != null) { mCloseGuard.close(); } } /** * This function is called every time the cursor is successfully scrolled Loading Loading @@ -224,8 +226,20 @@ public abstract class AbstractCursor implements CrossProcessCursor { /* Implementation */ public AbstractCursor() { mPos = -1; mCloseGuard = initCloseGuard(); if (mCloseGuard != null) { mCloseGuard.open("AbstractCursor.close"); } } @android.ravenwood.annotation.RavenwoodReplace private CloseGuard initCloseGuard() { return CloseGuard.get(); } private CloseGuard initCloseGuard$ravenwood() { return null; } @Override public final int getPosition() { Loading
core/java/android/database/CharArrayBuffer.java +1 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ package android.database; /** * This is used for {@link Cursor#copyStringToBuffer} */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public final class CharArrayBuffer { public CharArrayBuffer(int size) { data = new char[size]; Loading
core/java/android/database/ContentObservable.java +1 −0 Original line number Diff line number Diff line Loading @@ -23,6 +23,7 @@ import android.net.Uri; * that provides methods for sending notifications to a list of * {@link ContentObserver} objects. */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public class ContentObservable extends Observable<ContentObserver> { // Even though the generic method defined in Observable would be perfectly // fine on its own, we can't delete this overridden method because it would Loading
core/java/android/database/ContentObserver.java +11 −2 Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ import java.util.Collection; * Receives call backs for changes to content. * Must be implemented by objects which are added to a {@link ContentObservable}. */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public abstract class ContentObserver { /** * Starting in {@link android.os.Build.VERSION_CODES#R}, there is a new Loading @@ -49,7 +50,6 @@ public abstract class ContentObserver { @ChangeId @EnabledAfter(targetSdkVersion=android.os.Build.VERSION_CODES.Q) private static final long ADD_CONTENT_OBSERVER_FLAGS = 150939131L; private final Object mLock = new Object(); private Transport mTransport; // guarded by mLock Loading Loading @@ -216,7 +216,7 @@ public abstract class ContentObserver { // There are dozens of people relying on the hidden API inside the // system UID, so hard-code the old behavior for all of them; for // everyone else we gate based on a specific change if (!CompatChanges.isChangeEnabled(ADD_CONTENT_OBSERVER_FLAGS) if (!isChangeEnabledAddContentObserverFlags() || android.os.Process.myUid() == android.os.Process.SYSTEM_UID) { // Deliver userId through argument to preserve hidden API behavior onChange(selfChange, uris, flags, UserHandle.of(userId)); Loading @@ -225,6 +225,15 @@ public abstract class ContentObserver { } } @android.ravenwood.annotation.RavenwoodReplace private static boolean isChangeEnabledAddContentObserverFlags() { return CompatChanges.isChangeEnabled(ADD_CONTENT_OBSERVER_FLAGS); } private static boolean isChangeEnabledAddContentObserverFlags$ravenwood() { return true; } /** * Dispatches a change notification to the observer. * <p> Loading
core/java/android/database/Cursor.java +1 −0 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ import java.util.List; * Implementations should subclass {@link AbstractCursor}. * </p> */ @android.ravenwood.annotation.RavenwoodKeepWholeClass public interface Cursor extends Closeable { /* * Values returned by {@link #getType(int)}. Loading