|
14 | 14 | import static java.lang.annotation.ElementType.METHOD; |
15 | 15 | import static java.lang.annotation.RetentionPolicy.RUNTIME; |
16 | 16 |
|
17 | | -/** |
18 | | - * A simplified way to specify the type of the discriminator in an {@link Any} |
19 | | - * mapping, using the JPA-defined {@link DiscriminatorType}. This annotation |
20 | | - * must be used in combination with {@link jakarta.persistence.Column} to fully |
21 | | - * describe the discriminator column for an {@code @Any} relationship. |
22 | | - * <p> |
23 | | - * {@code @AnyDiscriminator} is quite similar to |
24 | | - * {@link jakarta.persistence.DiscriminatorColumn#discriminatorType()} in |
25 | | - * single-table inheritance mappings, but it describes a discriminator held |
26 | | - * along with the foreign key in the referring side of a discriminated |
27 | | - * relationship. |
28 | | - * <p> |
29 | | - * This annotation may be used in conjunction with {@link JdbcType} or |
30 | | - * {@link JdbcTypeCode} to more precisely specify the type mapping. On the |
31 | | - * other hand, {@link JdbcType} or {@link JdbcTypeCode} may be used without |
32 | | - * {@code @AnyDiscriminator}. |
33 | | - * |
34 | | - * @see Any |
35 | | - * @see AnyDiscriminatorValue |
36 | | - * @see AnyDiscriminatorImplicitValues |
37 | | - * |
38 | | - * @since 6.0 |
39 | | - */ |
| 17 | +/// A simplified way to specify the type of the discriminator in an [Any] |
| 18 | +/// mapping, using the JPA-defined [DiscriminatorType]. This annotation |
| 19 | +/// must be used in combination with [jakarta.persistence.Column] to fully |
| 20 | +/// describe the discriminator column for an `@Any` relationship. |
| 21 | +/// |
| 22 | +/// `@AnyDiscriminator` is quite similar to |
| 23 | +/// [jakarta.persistence.DiscriminatorColumn#discriminatorType()] in |
| 24 | +/// single-table inheritance mappings, but it describes a discriminator held |
| 25 | +/// along with the foreign key in the referring side of a discriminated |
| 26 | +/// relationship. |
| 27 | +/// |
| 28 | +/// This annotation may be used in conjunction with [JdbcType] or |
| 29 | +/// [JdbcTypeCode] to more precisely specify the type mapping. On the |
| 30 | +/// other hand, [JdbcType] or [JdbcTypeCode] may be used without |
| 31 | +/// `@AnyDiscriminator`. |
| 32 | +/// |
| 33 | +/// @see Any |
| 34 | +/// @see AnyDiscriminatorValue |
| 35 | +/// @see AnyDiscriminatorImplicitValues |
| 36 | +/// |
| 37 | +/// @since 6.0 |
40 | 38 | @Target({METHOD, FIELD, ANNOTATION_TYPE}) |
41 | 39 | @Retention( RUNTIME ) |
42 | 40 | public @interface AnyDiscriminator { |
43 | | - /** |
44 | | - * The type of the discriminator, as a JPA {@link DiscriminatorType}. |
45 | | - * For more precise specification of the type, use {@link JdbcType} |
46 | | - * or {@link JdbcTypeCode}. |
47 | | - */ |
| 41 | + /// The type of the discriminator, as a JPA [DiscriminatorType]. |
| 42 | + /// For more precise specification of the type, use [JdbcType] |
| 43 | + /// or [JdbcTypeCode]. |
48 | 44 | DiscriminatorType value() default DiscriminatorType.STRING; |
49 | 45 | } |
0 commit comments