java.lang.Object
java.lang.Record
org.tentackle.model.migrate.TableMigrator.Result
- Record Components:
hints- hints to control the created output, null or empty if nonecolumnMigrations- explicit column migrations, null or empty if nonerenameColumns- explicit column rename hints, null or empty if nonetableSql- the sql code to migrate the tableforeignKeySql- the sql code to migrate the foreign keyswarningSql- generated SQL as comments
- Enclosing class:
- TableMigrator
public static record TableMigrator.Result(Collection<Pattern> hints, Collection<ColumnMigration> columnMigrations, Map<String,String> renameColumns, String tableSql, String foreignKeySql, String warningSql)
extends Record
Migration result.
Contains the migration parameters and the resulting SQL code.
Contains the migration parameters and the resulting SQL code.
-
Constructor Summary
ConstructorsConstructorDescriptionResult(Collection<Pattern> hints, Collection<ColumnMigration> columnMigrations, Map<String, String> renameColumns, String tableSql, String foreignKeySql, String warningSql) Creates an instance of aResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecolumnMigrationsrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of theforeignKeySqlrecord component.final inthashCode()Returns a hash code value for this object.hints()Returns the value of thehintsrecord component.Returns the value of therenameColumnsrecord component.tableSql()Returns the value of thetableSqlrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thewarningSqlrecord component.
-
Constructor Details
-
Result
public Result(Collection<Pattern> hints, Collection<ColumnMigration> columnMigrations, Map<String, String> renameColumns, String tableSql, String foreignKeySql, String warningSql) Creates an instance of aResultrecord class.- Parameters:
hints- the value for thehintsrecord componentcolumnMigrations- the value for thecolumnMigrationsrecord componentrenameColumns- the value for therenameColumnsrecord componenttableSql- the value for thetableSqlrecord componentforeignKeySql- the value for theforeignKeySqlrecord componentwarningSql- the value for thewarningSqlrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
hints
Returns the value of thehintsrecord component.- Returns:
- the value of the
hintsrecord component
-
columnMigrations
Returns the value of thecolumnMigrationsrecord component.- Returns:
- the value of the
columnMigrationsrecord component
-
renameColumns
Returns the value of therenameColumnsrecord component.- Returns:
- the value of the
renameColumnsrecord component
-
tableSql
Returns the value of thetableSqlrecord component.- Returns:
- the value of the
tableSqlrecord component
-
foreignKeySql
Returns the value of theforeignKeySqlrecord component.- Returns:
- the value of the
foreignKeySqlrecord component
-
warningSql
Returns the value of thewarningSqlrecord component.- Returns:
- the value of the
warningSqlrecord component
-