diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2019-09-20 17:32:13 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2019-09-20 17:32:13 +0000 |
commit | 1d35d8456f420ada225c1e44102bfd705b8d9a3e (patch) | |
tree | e67951e5099eaa181d80e85319b539367de05f6e /dalvik | |
parent | b1e62050293dad2646f817420aaa3463a1757417 (diff) | |
parent | d333cbda2a2da0e5f20fc43b3f3e6866aa10c2ae (diff) |
Merge "Add @CovariantReturnType annotation to @CorePlatformApi."
Diffstat (limited to 'dalvik')
-rw-r--r-- | dalvik/src/main/java/dalvik/annotation/codegen/CovariantReturnType.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/dalvik/src/main/java/dalvik/annotation/codegen/CovariantReturnType.java b/dalvik/src/main/java/dalvik/annotation/codegen/CovariantReturnType.java index f3028506ac..b43600d93a 100644 --- a/dalvik/src/main/java/dalvik/annotation/codegen/CovariantReturnType.java +++ b/dalvik/src/main/java/dalvik/annotation/codegen/CovariantReturnType.java @@ -21,6 +21,7 @@ import java.lang.annotation.Repeatable; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; +import libcore.api.CorePlatformApi; /** * Indicates to the platform toolchain that there is an upcoming public SDK API change for a method. @@ -60,24 +61,29 @@ import java.lang.annotation.Target; @Repeatable(CovariantReturnType.CovariantReturnTypes.class) @Retention(RetentionPolicy.CLASS) @Target({ ElementType.METHOD}) +@CorePlatformApi public @interface CovariantReturnType { /** * The return type of the synthetic method to generate. Must be a subclass of the return type * of the method being annotated. */ + @CorePlatformApi Class<?> returnType(); /** * The last Android API level not to have the generated synthetic method. The annotation can be * removed and the actual return type updated when support for this API level is dropped. */ + @CorePlatformApi int presentAfter(); /** @hide */ @Retention(RetentionPolicy.CLASS) @Target({ElementType.METHOD}) + @CorePlatformApi @interface CovariantReturnTypes { + @CorePlatformApi CovariantReturnType[] value(); } } |