From e0d9a5a4f8b13de8b6fc69b7cfa8ed506de10728 Mon Sep 17 00:00:00 2001 From: Makoto Onuki Date: Tue, 4 Feb 2020 13:45:33 -0800 Subject: [PATCH] Finalize @SystemApi annotation Bug: 148177503 Test: Build & tree hugger Change-Id: I4f2394afcc25cdb2b03d58ebcc8d3fb1e4962e1e --- core/java/android/annotation/SystemApi.java | 36 +++------------------ 1 file changed, 4 insertions(+), 32 deletions(-) diff --git a/core/java/android/annotation/SystemApi.java b/core/java/android/annotation/SystemApi.java index ecbfed96cefd6..4ac00983af137 100644 --- a/core/java/android/annotation/SystemApi.java +++ b/core/java/android/annotation/SystemApi.java @@ -47,22 +47,14 @@ public @interface SystemApi { /** * Specifies that the intended clients of a SystemApi are privileged apps. * This is the default value for {@link #client}. - * TODO Update the javadoc according to the final spec */ PRIVILEGED_APPS, /** - * DO NOT USE. Use PRIVILEGED_APPS instead. - * (This would provide no further protection over PRIVILEGED_APPS; do not rely on it) - * @deprecated Use #PRIVILEGED_APPS instead - */ - @Deprecated - MODULE_APPS, - - /** - * Specifies that the intended clients of a SystemApi are modules implemented - * as libraries, like the conscrypt.jar in the conscrypt APEX. - * TODO Update the javadoc according to the final spec + * Specifies that the intended clients of a SystemApi are used by classes in + *
BOOTCLASSPATH
in mainline modules. Mainline modules can also expose + * this type of system APIs too when they're used only by the non-updatable + * platform code. */ MODULE_LIBRARIES, @@ -70,19 +62,6 @@ public @interface SystemApi { * Specifies that the system API is available only in the system server process. * Use this to expose APIs from code loaded by the system server process but * not in
BOOTCLASSPATH
. - * TODO(b/148177503) Update "services-stubs" and actually use it. - */ - SYSTEM_SERVER - } - - /** @deprecated do not use */ - @Deprecated - enum Process { - /** @deprecated do not use */ - ALL, - - /** - * @deprecated use Client#SYSTEM_SERVER instead */ SYSTEM_SERVER } @@ -92,13 +71,6 @@ public @interface SystemApi { */ Client client() default android.annotation.SystemApi.Client.PRIVILEGED_APPS; - /** - * @deprecated use Client#SYSTEM_SERVER instead for system_server APIs - */ - @Deprecated - Process process() default android.annotation.SystemApi.Process.ALL; - - /** * Container for {@link SystemApi} that allows it to be applied repeatedly to types. */