Class StandardForeignKeyExporter
java.lang.Object
org.hibernate.tool.schema.spi.StandardForeignKeyExporter
- All Implemented Interfaces:
Exporter<ForeignKey>
@SPI({USE,SUPPLY})
public final class StandardForeignKeyExporter
extends Object
implements Exporter<ForeignKey>
Stock exporter for relational ForeignKey constraints.
Instantiate this class when standard foreign-key DDL is sufficient. Compose
or implement Exporter when a database must decorate or replace the complete
operation, and supply the result from Dialect.getForeignKeyExporter().
- Since:
- 8.0
- See Also:
-
Field Summary
Fields inherited from interface Exporter
NO_COMMANDS -
Constructor Summary
ConstructorsConstructorDescriptionStandardForeignKeyExporter(Dialect dialect) Create a standard foreign-key exporter owned bydialect. -
Method Summary
Modifier and TypeMethodDescriptionString[]getSqlCreateStrings(ForeignKey foreignKey, Metadata metadata, SqlStringGenerationContext context) Return the commands needed to createexportable, in execution order.String[]getSqlDropStrings(ForeignKey foreignKey, Metadata metadata, SqlStringGenerationContext context) Return the commands needed to dropexportable, in execution order.
-
Constructor Details
-
StandardForeignKeyExporter
Create a standard foreign-key exporter owned bydialect.
-
-
Method Details
-
getSqlCreateStrings
public String[] getSqlCreateStrings(ForeignKey foreignKey, Metadata metadata, SqlStringGenerationContext context) Description copied from interface:ExporterReturn the commands needed to createexportable, in execution order.- Specified by:
getSqlCreateStringsin interfaceExporter<ForeignKey>
-
getSqlDropStrings
public String[] getSqlDropStrings(ForeignKey foreignKey, Metadata metadata, SqlStringGenerationContext context) Description copied from interface:ExporterReturn the commands needed to dropexportable, in execution order.- Specified by:
getSqlDropStringsin interfaceExporter<ForeignKey>
-