Package io.micronaut.data.annotation.sql
Annotation Interface JoinColumn
@Target({METHOD,FIELD})
@Retention(RUNTIME)
@Repeatable(JoinColumns.class)
public @interface JoinColumn
Subset of the JPA join column annotation.
- Since:
- 2.4.0
- Author:
- Denis Stepanov
-
Optional Element Summary
Modifier and TypeOptional ElementDescriptionUsed to define the mapping.The name of the foreign column.The name of the column referenced by this foreign column.
-
Element Details
-
name
String nameThe name of the foreign column.- Returns:
- The name of the foreign column
- Default:
- ""
-
referencedColumnName
String referencedColumnNameThe name of the column referenced by this foreign column.- Returns:
- The referenced column name
- Default:
- ""
-
columnDefinition
String columnDefinitionUsed to define the mapping. For example in the case of SQL this would be the column definition. Example: BLOB NOT NULL.- Returns:
- A string-based definition of the property type.
- Default:
- ""
-