Merge "Preparing to finalize @SystemApi"
This commit is contained in:
@@ -44,35 +44,43 @@ public @interface SystemApi {
|
|||||||
enum Client {
|
enum Client {
|
||||||
/**
|
/**
|
||||||
* Specifies that the intended clients of a SystemApi are privileged apps.
|
* Specifies that the intended clients of a SystemApi are privileged apps.
|
||||||
* This is the default value for {@link #client}. This implies
|
* This is the default value for {@link #client}.
|
||||||
* MODULE_APPS and MODULE_LIBRARIES as well, which means that APIs will also
|
* TODO Update the javadoc according to the final spec
|
||||||
* be available to module apps and jars.
|
|
||||||
*/
|
*/
|
||||||
PRIVILEGED_APPS,
|
PRIVILEGED_APPS,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Specifies that the intended clients of a SystemApi are modules implemented
|
* DO NOT USE. Use PRIVILEGED_APPS instead.
|
||||||
* as apps, like the NetworkStack app. This implies MODULE_LIBRARIES as well,
|
* (This would provide no further protection over PRIVILEGED_APPS; do not rely on it)
|
||||||
* which means that APIs will also be available to module jars.
|
* @deprecated Use #PRIVILEGED_APPS instead
|
||||||
*/
|
*/
|
||||||
|
@Deprecated
|
||||||
MODULE_APPS,
|
MODULE_APPS,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Specifies that the intended clients of a SystemApi are modules implemented
|
* Specifies that the intended clients of a SystemApi are modules implemented
|
||||||
* as libraries, like the conscrypt.jar in the conscrypt APEX.
|
* as libraries, like the conscrypt.jar in the conscrypt APEX.
|
||||||
|
* TODO Update the javadoc according to the final spec
|
||||||
*/
|
*/
|
||||||
MODULE_LIBRARIES
|
MODULE_LIBRARIES,
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 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 <em>but</em>
|
||||||
|
* not in <pre>BOOTCLASSPATH</pre>.
|
||||||
|
* TODO(b/148177503) Update "services-stubs" and actually use it.
|
||||||
|
*/
|
||||||
|
SYSTEM_SERVER
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** @deprecated do not use */
|
||||||
|
@Deprecated
|
||||||
enum Process {
|
enum Process {
|
||||||
/**
|
/** @deprecated do not use */
|
||||||
* Specifies that the SystemAPI is available in every Java processes.
|
|
||||||
* This is the default value for {@link #process}.
|
|
||||||
*/
|
|
||||||
ALL,
|
ALL,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Specifies that the SystemAPI is available only in the system server process.
|
* @deprecated use Client#SYSTEM_SERVER instead
|
||||||
*/
|
*/
|
||||||
SYSTEM_SERVER
|
SYSTEM_SERVER
|
||||||
}
|
}
|
||||||
@@ -83,7 +91,8 @@ public @interface SystemApi {
|
|||||||
Client client() default android.annotation.SystemApi.Client.PRIVILEGED_APPS;
|
Client client() default android.annotation.SystemApi.Client.PRIVILEGED_APPS;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The process(es) that this SystemAPI is available
|
* @deprecated use Client#SYSTEM_SERVER instead for system_server APIs
|
||||||
*/
|
*/
|
||||||
|
@Deprecated
|
||||||
Process process() default android.annotation.SystemApi.Process.ALL;
|
Process process() default android.annotation.SystemApi.Process.ALL;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user