Class ColumnOrderingStrategyStandard
java.lang.Object
org.hibernate.boot.model.relational.ColumnOrderingStrategyStandard
- All Implemented Interfaces:
ColumnOrderingStrategy
Standard implementation that orders columns by size and name following roughly this ordering:
order by max(physicalSizeBytes, 4), physicalSizeBytes > 2048, name
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static class
protected static class
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorderColumns
(Collection<Column> columns, Metadata metadata) orderConstraintColumns
(Constraint constraint, Metadata metadata) Orders the columns of the constraint.orderTableColumns
(Table table, Metadata metadata) Orders the columns of the table.void
orderTemporaryTableColumns
(List<TemporaryTableColumn> temporaryTableColumns, Metadata metadata) Orders the columns of the temporary table.orderUserDefinedTypeColumns
(UserDefinedObjectType userDefinedType, Metadata metadata) Orders the columns of the user defined type.protected static int
physicalSizeInBytes
(int sqlTypeCode, Size columnSize, Metadata metadata)
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
ColumnOrderingStrategyStandard
public ColumnOrderingStrategyStandard()
-
-
Method Details
-
orderTableColumns
Description copied from interface:ColumnOrderingStrategy
Orders the columns of the table. May return null if columns were not ordered.- Specified by:
orderTableColumns
in interfaceColumnOrderingStrategy
-
orderUserDefinedTypeColumns
public List<Column> orderUserDefinedTypeColumns(UserDefinedObjectType userDefinedType, Metadata metadata) Description copied from interface:ColumnOrderingStrategy
Orders the columns of the user defined type. May return null if columns were not ordered.- Specified by:
orderUserDefinedTypeColumns
in interfaceColumnOrderingStrategy
-
orderConstraintColumns
Description copied from interface:ColumnOrderingStrategy
Orders the columns of the constraint. May return null if columns were not ordered.- Specified by:
orderConstraintColumns
in interfaceColumnOrderingStrategy
-
orderTemporaryTableColumns
public void orderTemporaryTableColumns(List<TemporaryTableColumn> temporaryTableColumns, Metadata metadata) Description copied from interface:ColumnOrderingStrategy
Orders the columns of the temporary table.- Specified by:
orderTemporaryTableColumns
in interfaceColumnOrderingStrategy
-
orderColumns
-
physicalSizeInBytes
-