Merge "Add isStable in Parcelable interface" am: ed760b0671 am: f4b4f48ae2 am: e965571db4
Change-Id: Ic1ab5edd28fe1da9b26d8dd50b63194650b85891
diff --git a/libs/binder/include/binder/Parcelable.h b/libs/binder/include/binder/Parcelable.h
index a9166e2..c113279 100644
--- a/libs/binder/include/binder/Parcelable.h
+++ b/libs/binder/include/binder/Parcelable.h
@@ -52,6 +52,12 @@
//
// Returns android::OK on success and an appropriate error otherwise.
virtual status_t readFromParcel(const Parcel* parcel) = 0;
+
+ // 'Stable' means this parcelable is guaranteed to be stable for multiple years.
+ // It must be guaranteed by setting stability field in aidl_interface.
+ // WARNING: isStable() is only expected to be overridden by auto-generated code.
+ // Returns true if this parcelable is stable.
+ virtual bool isStable() const { return false; }
}; // class Parcelable
#if defined(__clang__)