Annotation Type Many2Many
-
@Retention(RUNTIME) @Target(TYPE) @Repeatable(Many2Manies.class) public @interface Many2Many
Use this annotation to override conventions in cases where they are impossible to follow. This annotation does not have to be placed on two models, one is sufficient.- Author:
- Igor Polevoy
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description StringjoinName of a table used for joining records from other tables.Class<? extends Model>otherThis is a type of a model that is the "other" end of the relationship.StringsourceFKNameForeign key name of a source table in the join.StringtargetFKNameForeign key name of a target table in the join table.
-
-
-
-
join
String join
Name of a table used for joining records from other tables.
-
-
-
sourceFKName
String sourceFKName
Foreign key name of a source table in the join. A "source" table is a table that backs the model on which this annotation is used.
-
-
-
targetFKName
String targetFKName
Foreign key name of a target table in the join table. A "target" table is a table that backs the "other" model.
-
-