Loading core/api/current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -32953,11 +32953,16 @@ package android.os { public class Build { ctor public Build(); method @FlaggedApi("android.os.api_for_backported_fixes") public static int getBackportedFixStatus(long); method @NonNull public static java.util.List<android.os.Build.Partition> getFingerprintedPartitions(); method @FlaggedApi("android.sdk.major_minor_versioning_scheme") public static int getMajorSdkVersion(int); method @FlaggedApi("android.sdk.major_minor_versioning_scheme") public static int getMinorSdkVersion(int); method public static String getRadioVersion(); method @RequiresPermission("android.permission.READ_PRIVILEGED_PHONE_STATE") public static String getSerial(); field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_FIXED = 1; // 0x1 field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_NOT_APPLICABLE = 2; // 0x2 field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_NOT_FIXED = 3; // 0x3 field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_UNKNOWN = 0; // 0x0 field public static final String BOARD; field public static final String BOOTLOADER; field public static final String BRAND; core/java/android/os/Build.java +55 −0 Original line number Diff line number Diff line Loading @@ -1565,6 +1565,61 @@ public class Build { /** A string that uniquely identifies this build. Do not attempt to parse this value. */ public static final String FINGERPRINT = deriveFingerprint(); /** The status of the known issue on this device is not known. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_UNKNOWN = 0; /** The known issue is fixed on this device. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_FIXED = 1; /** * The known issue is not applicable to this device. * * <p>For example if the issue only affects a specific brand, devices * from other brands would report not applicable. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_NOT_APPLICABLE = 2; /** The known issue is not fixed on this device. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_NOT_FIXED = 3; /** * The status of the backported fix for a known issue on this device. * * @hide */ @IntDef( prefix = {"BACKPORTED_FIX_STATUS_"}, value = { BACKPORTED_FIX_STATUS_UNKNOWN, BACKPORTED_FIX_STATUS_FIXED, BACKPORTED_FIX_STATUS_NOT_APPLICABLE, BACKPORTED_FIX_STATUS_NOT_FIXED, }) @Retention(RetentionPolicy.SOURCE) public @interface BackportedFixStatus { } /** * The status of the backported fix for a known issue on this device. * * @param id The id of the known issue to check. * @return {@link #BACKPORTED_FIX_STATUS_FIXED} if the known issue is * fixed on this device, * {@link #BACKPORTED_FIX_STATUS_NOT_FIXED} if the known issue is not * fixed on this device, * {@link #BACKPORTED_FIX_STATUS_NOT_APPLICABLE} if the known issue is * is not applicable on this device, * otherwise {@link #BACKPORTED_FIX_STATUS_UNKNOWN}. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static @BackportedFixStatus int getBackportedFixStatus(long id) { // TODO: b/308461809 - query aliases from system prop // TODO: b/372518979 - use backported fix datastore. return BACKPORTED_FIX_STATUS_UNKNOWN; } /** * Some devices split the fingerprint components between multiple * partitions, so we might derive the fingerprint at runtime. Loading Loading
core/api/current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -32953,11 +32953,16 @@ package android.os { public class Build { ctor public Build(); method @FlaggedApi("android.os.api_for_backported_fixes") public static int getBackportedFixStatus(long); method @NonNull public static java.util.List<android.os.Build.Partition> getFingerprintedPartitions(); method @FlaggedApi("android.sdk.major_minor_versioning_scheme") public static int getMajorSdkVersion(int); method @FlaggedApi("android.sdk.major_minor_versioning_scheme") public static int getMinorSdkVersion(int); method public static String getRadioVersion(); method @RequiresPermission("android.permission.READ_PRIVILEGED_PHONE_STATE") public static String getSerial(); field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_FIXED = 1; // 0x1 field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_NOT_APPLICABLE = 2; // 0x2 field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_NOT_FIXED = 3; // 0x3 field @FlaggedApi("android.os.api_for_backported_fixes") public static final int BACKPORTED_FIX_STATUS_UNKNOWN = 0; // 0x0 field public static final String BOARD; field public static final String BOOTLOADER; field public static final String BRAND;
core/java/android/os/Build.java +55 −0 Original line number Diff line number Diff line Loading @@ -1565,6 +1565,61 @@ public class Build { /** A string that uniquely identifies this build. Do not attempt to parse this value. */ public static final String FINGERPRINT = deriveFingerprint(); /** The status of the known issue on this device is not known. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_UNKNOWN = 0; /** The known issue is fixed on this device. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_FIXED = 1; /** * The known issue is not applicable to this device. * * <p>For example if the issue only affects a specific brand, devices * from other brands would report not applicable. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_NOT_APPLICABLE = 2; /** The known issue is not fixed on this device. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static final int BACKPORTED_FIX_STATUS_NOT_FIXED = 3; /** * The status of the backported fix for a known issue on this device. * * @hide */ @IntDef( prefix = {"BACKPORTED_FIX_STATUS_"}, value = { BACKPORTED_FIX_STATUS_UNKNOWN, BACKPORTED_FIX_STATUS_FIXED, BACKPORTED_FIX_STATUS_NOT_APPLICABLE, BACKPORTED_FIX_STATUS_NOT_FIXED, }) @Retention(RetentionPolicy.SOURCE) public @interface BackportedFixStatus { } /** * The status of the backported fix for a known issue on this device. * * @param id The id of the known issue to check. * @return {@link #BACKPORTED_FIX_STATUS_FIXED} if the known issue is * fixed on this device, * {@link #BACKPORTED_FIX_STATUS_NOT_FIXED} if the known issue is not * fixed on this device, * {@link #BACKPORTED_FIX_STATUS_NOT_APPLICABLE} if the known issue is * is not applicable on this device, * otherwise {@link #BACKPORTED_FIX_STATUS_UNKNOWN}. */ @FlaggedApi(android.os.Flags.FLAG_API_FOR_BACKPORTED_FIXES) public static @BackportedFixStatus int getBackportedFixStatus(long id) { // TODO: b/308461809 - query aliases from system prop // TODO: b/372518979 - use backported fix datastore. return BACKPORTED_FIX_STATUS_UNKNOWN; } /** * Some devices split the fingerprint components between multiple * partitions, so we might derive the fingerprint at runtime. Loading