Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6c310a5a authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Add isStable in Parcelable interface" am: 9bb27b03 am: a5ace2e7 am: 27bfb770

Change-Id: Iacdc816adcd402130441f2ca16d51d0675d51ece
parents 900efd6f 27bfb770
Loading
Loading
Loading
Loading
+15 −1
Original line number Diff line number Diff line
@@ -119,6 +119,20 @@ public interface Parcelable {
     */
    public @ContentsFlags int describeContents();

    /**
     * 'Stable' means this parcelable is guaranteed to be stable for multiple years.
     * It must be guaranteed by setting stability field in aidl_interface,
     * OR explicitly override this method from @JavaOnlyStableParcelable marked Parcelable.
     * WARNING: isStable() is only expected to be overridden by auto-generated code,
     * OR @JavaOnlyStableParcelable marked Parcelable only if there is guaranteed to
     * be only once copy of the parcelable on the system.
     * @return true if this parcelable is stable.
     * @hide
     */
    default boolean isStable() {
        return false;
    }

    /**
     * Flatten this object in to a Parcel.
     *