Skip to content

Commit

Permalink
Improve documentation on Discriminatorcolumn
Browse files Browse the repository at this point in the history
Signed-off-by: Otavio Santana <otaviopolianasantana@gmail.com>
  • Loading branch information
otaviojava committed Jul 2, 2022
1 parent ec94dc5 commit 2ed748e
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,17 @@
import java.lang.annotation.Target;

/**
* Specifies that the class is an entity. This annotation is applied to the entity class.
* Specifies the discriminator column for the mapping strategy.
*
* If the <code>DiscriminatorColumn</code> annotation is missing,
* the name of the discriminator column defaults is <code>"type"</code>.
*/
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
@Stereotype
public @interface DiscriminatorColumn {
/**
* The name of an entity. Defaults to the unqualified name of the entity class.
* @return the entity name (Optional)
* (Optional) The name of column to be used for the discriminator.
*/
String value() default "";
String value() default "type";
}

0 comments on commit 2ed748e

Please sign in to comment.