Skip to content

Commit

Permalink
HHH-17441 - Deprecate @comment
Browse files Browse the repository at this point in the history
  • Loading branch information
sebersole committed Mar 28, 2024
1 parent b225b35 commit fc98535
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
Expand Up @@ -13,6 +13,8 @@
import java.lang.annotation.Retention;
import java.lang.annotation.Target;

import jakarta.persistence.Table;

import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.METHOD;
import static java.lang.annotation.ElementType.TYPE;
Expand Down Expand Up @@ -49,13 +51,14 @@
* @author Yanming Zhou
* @author Gavin King
*
* @remove JPA 3.2 adds a comment attribute to {@linkplain jakarta.persistence.Table}
* @deprecated Prefer {@linkplain Table#comment()}
*/
@TypeBinderType(binder = CommentBinder.class)
@AttributeBinderType(binder = CommentBinder.class)
@Target({METHOD, FIELD, TYPE})
@Retention(RUNTIME)
@Repeatable(Comments.class)
@Deprecated
@Remove
public @interface Comment {
/**
Expand Down
Expand Up @@ -12,6 +12,8 @@
import java.lang.annotation.Retention;
import java.lang.annotation.Target;

import jakarta.persistence.Table;

import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.METHOD;
import static java.lang.annotation.ElementType.TYPE;
Expand All @@ -25,12 +27,13 @@
*
* @author Gavin King
*
* @remove JPA 3.2 adds a comment attribute to {@linkplain jakarta.persistence.Table}
* @deprecated Per {@linkplain Comment}, prefer {@linkplain Table#comment()}
*/
@TypeBinderType(binder = CommentsBinder.class)
@AttributeBinderType(binder = CommentsBinder.class)
@Target({METHOD, FIELD, TYPE})
@Retention(RUNTIME)
@Deprecated
@Remove
public @interface Comments {
Comment[] value();
Expand Down

0 comments on commit fc98535

Please sign in to comment.