Skip to content

Commit

Permalink
add ApiStatus.Obsolete annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
dovchinnikov authored and chashnikov committed Dec 8, 2022
1 parent 30daf99 commit d4b23e8
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
19 changes: 19 additions & 0 deletions common/src/main/java/org/jetbrains/annotations/ApiStatus.java
Expand Up @@ -72,6 +72,25 @@ private ApiStatus() {
})
public @interface Internal {}

/**
* <p>Indicates that a public API of the annotated element (class, method or field) is subject to deprecation in a future version.
* It's a weaker variant of {@link Deprecated} annotation.
* The annotated API is not supposed to be used in the new code because a better API exists,
* but it's permitted to postpone the migration of the existing code, therefore the usage is not considered a warning.
* </p>
*/
@Documented
@Retention(RetentionPolicy.CLASS)
@Target({
ElementType.TYPE, ElementType.ANNOTATION_TYPE, ElementType.METHOD, ElementType.CONSTRUCTOR, ElementType.FIELD, ElementType.PACKAGE
})
public @interface Obsolete {
/**
* Specifies in which version the API became obsolete.
*/
String since() default "";
}

/**
* <p>Indicates that a public API of the annotated element (class, method or field) is subject to removal in a future version.
* It's a stronger variant of {@link Deprecated} annotation.</p>
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Expand Up @@ -14,5 +14,5 @@
# limitations under the License.
#

projectVersion=23.0.1
projectVersion=23.1.0
#JDK_5=<path-to-older-java-version>

0 comments on commit d4b23e8

Please sign in to comment.