OpenJDK / jdk / jdk
changeset 21484:c64ceb9090aa
8026984: Clarity intended use of jdk.Exported
Reviewed-by: psandoz, mr, alanb
author | darcy |
---|---|
date | Mon, 21 Oct 2013 15:37:11 -0700 |
parents | bda04738a55a |
children | 2759750a8cdf |
files | langtools/src/share/classes/jdk/Exported.java |
diffstat | 1 files changed, 24 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/langtools/src/share/classes/jdk/Exported.java Mon Oct 21 15:55:02 2013 +0100 +++ b/langtools/src/share/classes/jdk/Exported.java Mon Oct 21 15:37:11 2013 -0700 @@ -38,7 +38,30 @@ * com.sun.*} are official parts of the JDK meant to be generally * usable while other portions of {@code com.sun.*} are not. This * annotation type allows those portions to be easily and - * programmaticly distinguished. + * programmatically distinguished. + * + * <p>If in one release a type or package is + * <code>@Exported(true)</code>, in a subsequent major release such a + * type or package can transition to <code>@Exported(false)</code>. + * + * <p>If a type or package is <code>@Exported(false)</code> in a + * release, it may be removed in a subsequent major release. + * + * <p>If a top-level type has an <code>@Exported</code> annotation, + * any nested member types with the top-level type should have an + * <code>@Exported</code> annotation with the same value. + * + * (In exceptional cases, if a nested type is going to be removed + * before its enclosing type, the nested type's could be + * <code>@Exported(false)</code> while its enclosing type was + * <code>@Exported(true)</code>.) + * + * Likewise, if a package has an <code>@Exported</code> annotation, + * top-level types within that package should also have an + * <code>@Exported</code> annotation. + * + * Sometimes a top-level type may have a different + * <code>@Exported</code> value than its package. * * @since 1.8 */