Class ForeignKeyConstraint

java.lang.Object
com.github.tadukoo.database.mysql.syntax.ForeignKeyConstraint

public class ForeignKeyConstraint extends Object
Foreign Key Constraint represents a foreign key constraint in MySQL
Version:
Alpha v.0.3
Author:
Logan Ferree (Tadukoo)
  • Field Details

    • columnNames

      private final List<String> columnNames
      The names of the columns for the foreign key
    • referenceTable

      private final String referenceTable
      The name of the reference table for the foreign key
    • referenceColumnNames

      private final List<String> referenceColumnNames
      The names of the columns from the reference table
    • onDeleteOption

      private final SQLReferenceOption onDeleteOption
      The reference option for on delete
    • onUpdateOption

      private final SQLReferenceOption onUpdateOption
      The reference option for on update
  • Constructor Details

    • ForeignKeyConstraint

      private ForeignKeyConstraint(List<String> columnNames, String referenceTable, List<String> referenceColumnNames, SQLReferenceOption onDeleteOption, SQLReferenceOption onUpdateOption)
      Constructs a new ForeignKeyConstraint using the given parameters
      Parameters:
      columnNames - The names of the columns for the foreign key
      referenceTable - The name of the reference table for the foreign key
      referenceColumnNames - The names of the columns from the reference table
      onDeleteOption - The reference option for on delete
      onUpdateOption - The reference option for on update
  • Method Details