@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
public @interface Table {
Stringname() default"default";
}
// The @Table annotation can have an optional name argument which specifies the table name. // If not specified, the class name with normalized case is used by default.
Column
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.FIELD)
public @interface Column {
booleanprimary() defaultfalse;
booleanai() defaultfalse;
Stringtype() default"int";
intsize() default11;
}
// The @Column annotation can have an optional primary, type and size arguments which specifies the column propetries. // If not specified, the class name with normalized case is used by default.