jodd.db.orm.sqlgen.fk
Interface FkNamingConvention

All Known Implementing Classes:
DefaultFkNamingConvention

public interface FkNamingConvention

Generates foreign key for some table.


Method Summary
 java.lang.String resolveFkName(DbEntityDescriptor foreignTable, DbEntityDescriptor thisTable)
          Resolve foreign key name from foreign table and this table.
 

Method Detail

resolveFkName

java.lang.String resolveFkName(DbEntityDescriptor foreignTable,
                               DbEntityDescriptor thisTable)
Resolve foreign key name from foreign table and this table.

Example: Lets have table GIRL that has an ID column. Lets have table BOY that has a foreign key to a GIRL. In this example, method will receive following arguments:

  • foreignTable = (GIRL)
  • thisTable = (BOY) The resulting foreign key might be: "GIRL_ID".



  • Copyright ©2008 Jodd Team