javax.jdo.metadata

## Interface ForeignKeyMetadata

- All Superinterfaces:
    Metadata

      public interface ForeignKeyMetadata
      extends Metadata

  Represents a FK constraint in an ORM context.
  Since:
    3.0

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `ColumnMetadata[]` | `getColumns()` Accessor for all column(s) defined on the FK.
    `Boolean` | `getDeferred()` Accessor for whether the constraint can be deferred.
    `ForeignKeyAction` | `getDeleteAction()` Accessor for the delete action of the FK.
    `MemberMetadata[]` | `getMembers()` Accessor for all fields/properties defined on the FK.
    `String` | `getName()` Accessor for the constraint name.
    `int` | `getNumberOfColumns()` Accessor for the number of columns defined for this FK.
    `int` | `getNumberOfMembers()` Accessor for the number of fields/properties defined for this FK.
    `String` | `getTable()` Accessor for the name of the table.
    `Boolean` | `getUnique()` Accessor for whether unique.
    `ForeignKeyAction` | `getUpdateAction()` Accessor for the update action of the FK.
    `ColumnMetadata` | `newColumnMetadata()` Add a new column for this FK.
    `FieldMetadata` | `newFieldMetadata(String name)` Add a new field for this FK.
    `PropertyMetadata` | `newPropertyMetadata(String name)` Add a new property for this FK.
    `ForeignKeyMetadata` | `setDeferred(boolean def)` Method to set whether it is deferred.
    `ForeignKeyMetadata` | `setDeleteAction(ForeignKeyAction action)` Method to set the delete action of the FK
    `ForeignKeyMetadata` | `setName(String name)` Method to set the name of the constraint
    `ForeignKeyMetadata` | `setTable(String table)` Method to set the table name.
    `ForeignKeyMetadata` | `setUnique(boolean unique)` Method to set whether it is unique.
    `ForeignKeyMetadata` | `setUpdateAction(ForeignKeyAction action)` Method to set the update action of the FK.

    - ### Methods inherited from interface javax.jdo.metadata.Metadata

      `getExtensions, getNumberOfExtensions, getParent, newExtensionMetadata`

- - ### Method Detail

    - #### setName

          ForeignKeyMetadata setName(String name)

      Method to set the name of the constraint
      Parameters:
        `name` - Name of the constraint
      Returns:
        This metadata object

    - #### getName

          String getName()

      Accessor for the constraint name.
      Returns:
        The constraint name

    - #### setTable

          ForeignKeyMetadata setTable(String table)

      Method to set the table name.
      Parameters:
        `table` - Table name
      Returns:
        This metadata object

    - #### getTable

          String getTable()

      Accessor for the name of the table.
      Returns:
        The name

    - #### setUnique

          ForeignKeyMetadata setUnique(boolean unique)

      Method to set whether it is unique.
      Parameters:
        `unique` - Unique?
      Returns:
        This metadata object

    - #### getUnique

          Boolean getUnique()

      Accessor for whether unique.
      Returns:
        Unique?

    - #### setDeferred

          ForeignKeyMetadata setDeferred(boolean def)

      Method to set whether it is deferred.
      Parameters:
        `def` - Deferred?
      Returns:
        This metadata object

    - #### getDeferred

          Boolean getDeferred()

      Accessor for whether the constraint can be deferred.
      Returns:
        Deferred?

    - #### setDeleteAction

          ForeignKeyMetadata setDeleteAction(ForeignKeyAction action)

      Method to set the delete action of the FK
      Parameters:
        `action` - Delete action of the FK
      Returns:
        This metadata object

    - #### getDeleteAction

          ForeignKeyAction getDeleteAction()

      Accessor for the delete action of the FK.
      Returns:
        The FK delete-action

    - #### setUpdateAction

          ForeignKeyMetadata setUpdateAction(ForeignKeyAction action)

      Method to set the update action of the FK.
      Parameters:
        `action` - Update action of the FK
      Returns:
        This metadata object

    - #### getUpdateAction

          ForeignKeyAction getUpdateAction()

      Accessor for the update action of the FK.
      Returns:
        The FK update-action

    - #### getColumns

          ColumnMetadata[] getColumns()

      Accessor for all column(s) defined on the FK.
      Returns:
        The column(s)

    - #### newColumnMetadata

          ColumnMetadata newColumnMetadata()

      Add a new column for this FK.
      Returns:
        The ColumnMetadata

    - #### getNumberOfColumns

          int getNumberOfColumns()

      Accessor for the number of columns defined for this FK.
      Returns:
        The number of columns

    - #### getMembers

          MemberMetadata[] getMembers()

      Accessor for all fields/properties defined on the FK.
      Returns:
        The members

    - #### getNumberOfMembers

          int getNumberOfMembers()

      Accessor for the number of fields/properties defined for this FK.
      Returns:
        The number of members

    - #### newFieldMetadata

          FieldMetadata newFieldMetadata(String name)

      Add a new field for this FK.
      Parameters:
        `name` - Name of the field
      Returns:
        The FieldMetadata

    - #### newPropertyMetadata

          PropertyMetadata newPropertyMetadata(String name)

      Add a new property for this FK.
      Parameters:
        `name` - Name of the property
      Returns:
        The PropertyMetadata

Copyright © 2005–1970 Apache Software Foundation. All rights reserved.