Class DialectEventDdlTranslator
java.lang.Object
io.hypersistence.optimizer.core.event.persistence.DialectEventDdlTranslator
- All Implemented Interfaces:
EventDdlTranslator
Resolves DDL fragments using the host's registered Hibernate 6/7 SQL types.
-
Constructor Summary
ConstructorsConstructorDescriptionDialectEventDdlTranslator(org.hibernate.dialect.Dialect dialect, org.hibernate.SessionFactory sessionFactory) -
Method Summary
Modifier and TypeMethodDescriptionaddForeignKeyDefinition(String constraintName, String column, String referencedTable, String referencedColumn) TheALTER TABLEfragment that adds a foreign key referencing a primary key column, starting withadd constraint.columnType(int sqlType, int length) booleanboolean
-
Constructor Details
-
DialectEventDdlTranslator
public DialectEventDdlTranslator(org.hibernate.dialect.Dialect dialect, org.hibernate.SessionFactory sessionFactory)
-
-
Method Details
-
columnType
- Specified by:
columnTypein interfaceEventDdlTranslator
-
supportsIdentity
public boolean supportsIdentity()- Specified by:
supportsIdentityin interfaceEventDdlTranslator
-
hasDataTypeInIdentityColumn
public boolean hasDataTypeInIdentityColumn()- Specified by:
hasDataTypeInIdentityColumnin interfaceEventDdlTranslator
-
identityColumnDefinition
- Specified by:
identityColumnDefinitionin interfaceEventDdlTranslator
-
nullableColumnDefinition
- Specified by:
nullableColumnDefinitionin interfaceEventDdlTranslator
-
addForeignKeyDefinition
public String addForeignKeyDefinition(String constraintName, String column, String referencedTable, String referencedColumn) Description copied from interface:EventDdlTranslatorTheALTER TABLEfragment that adds a foreign key referencing a primary key column, starting withadd constraint.- Specified by:
addForeignKeyDefinitionin interfaceEventDdlTranslator
-