Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.openjpa.jdbc.meta
Interface MappingInfo.ForeignKeyDefaults

Enclosing class:
  MappingInfo

    public static interface MappingInfo.ForeignKeyDefaults

Supplies default foreign key information.

Method Summary
`ForeignKey` | `get(Table local, Table foreign, boolean inverse)` Return a default foreign key for the given tables, or null to create a logical foreign key only.
`void` | `populate(Table local, Table foreign, Column col, Object target, boolean inverse, int pos, int cols)` Populate the given foreign key column with defaults.

Method Detail

### get

    ForeignKey get(Table local,
                   Table foreign,
                   boolean inverse)

  Return a default foreign key for the given tables, or null to create a logical foreign key only. Do not fill in the columns of the foreign key, only attributes like its name, delete action, etc. Do not add the foreign key to the table.

### populate

    void populate(Table local,
                  Table foreign,
                  Column col,
                  Object target,
                  boolean inverse,
                  int pos,
                  int cols)

  Populate the given foreign key column with defaults.

  Parameters:
    `target` - the target column or constant value
    `pos` - the index of this column in the foreign key
    `cols` - the number of columns in the foreign key

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006-2013 Apache Software Foundation. All Rights Reserved.