@Documented
@Retention(value=RUNTIME)
public @interface Removal
Program elements annotated @Removal track the earliest final release when a deprecated feature will be removed. This is an internal decoration: a feature may be removed in a release earlier or later than the release number specified by this annotation.
The POI project policy is to deprecate an element for 2 final releases before removing. This annotation exists to make it easier to follow up on the second step of the two-step deprecate and remove process.
A deprecated feature may be removed in nightly and beta releases prior to the final release for which it is eligible, but may be removed later for various reasons. If it is known in advance that the feature will not be removed in the n+2 release, a later version should be specified by this annotation. The annotation version number should not include beta
For example, a feature with a @deprecated POI 3.15 beta 3
is deprecated in POI 3.15 and 3.16 and becomes eligible for deletion during the POI 3.17 release series, and may be deleted immediately after POI 3.16 is released. This would be annotated @Removal(version="3.17")
.
(注释 @Removal 的程序元素会跟踪最早的最终版本,届时将删除已弃用的功能。这是一种内部装饰:可以在早于或晚于此注释指定的版本号的版本中删除功能。 POI 项目政策是在删除之前弃用 2 个最终版本的元素。存在此注释是为了更容易跟进两步弃用和删除过程的第二步。不推荐使用的功能可能会在其符合条件的最终版本之前的每晚版本和 beta 版本中被删除,但以后可能会因各种原因而被删除。如果事先知道该功能不会在 n+2 版本中删除,则应通过此注解指定更高版本。注释版本号不应包含 beta 例如,带有@deprecated POI 3.15 beta 3 的功能在 POI 3.15 和 3.16 中已被弃用,并且在 POI 3.17 发布系列期间符合删除条件,并且可能在 POI 3.16 发布后立即删除.这将被注释为@Removal(version="3.17")。)
-
Since:
-
POI-3.15 beta 3
-
-
Optional Element Summary
Optional Elements
Modifier and Type
Optional Element and Description
java.lang.String
version
The POI version when this feature may be removed.
(此功能可能被删除时的 POI 版本。)
-
-
Element Detail
-
version
public abstract java.lang.String version
The POI version when this feature may be removed. To ensure that the version number can be compared to the current version and a unit test can generate a warning if a removal-eligible feature has not been removed yet, the version number should adhere to the following format: Format: "(?
\d+)\.(?
\d+)" Example: "3.15"
(此功能可能被删除时的 POI 版本。为了确保可以将版本号与当前版本进行比较,并且如果尚未删除符合删除条件的功能,则单元测试可以生成警告,版本号应遵循以下格式:格式:“(?d+) .(?d+)" 示例:"3.15")
-
Default:
-
""
Copyright 2021 The Apache Software Foundation or its licensors, as applicable.