33
33
import org .hibernate .type .EntityType ;
34
34
import org .hibernate .type .Type ;
35
35
import org .hibernate .type .descriptor .JdbcTypeNameMapper ;
36
- import org .hibernate .type .descriptor .java .JavaTypeHelper ;
37
36
import org .hibernate .type .descriptor .jdbc .JdbcType ;
38
37
import org .hibernate .type .descriptor .sql .DdlType ;
39
38
import org .hibernate .type .descriptor .sql .spi .DdlTypeRegistry ;
44
43
import static org .hibernate .internal .util .StringHelper .lastIndexOfLetter ;
45
44
import static org .hibernate .internal .util .StringHelper .nullIfEmpty ;
46
45
import static org .hibernate .internal .util .StringHelper .safeInterning ;
46
+ import static org .hibernate .type .descriptor .java .JavaTypeHelper .isTemporal ;
47
47
48
48
/**
49
49
* A mapping model object representing a {@linkplain jakarta.persistence.Column column}
@@ -311,7 +311,7 @@ public int getSqlTypeCode(Mapping mapping) throws MappingException {
311
311
private String getSqlTypeName (DdlTypeRegistry ddlTypeRegistry , Dialect dialect , Mapping mapping ) {
312
312
if ( sqlTypeName == null ) {
313
313
final int typeCode = getSqlTypeCode ( mapping );
314
- final DdlType descriptor = ddlTypeRegistry .getDescriptor ( getSqlTypeCode ( mapping ) );
314
+ final DdlType descriptor = ddlTypeRegistry .getDescriptor ( typeCode );
315
315
if ( descriptor == null ) {
316
316
throw new MappingException (
317
317
String .format (
@@ -455,7 +455,7 @@ Size calculateColumnSize(Dialect dialect, Mapping mapping) {
455
455
}
456
456
if ( type instanceof BasicType ) {
457
457
final BasicType <?> basicType = (BasicType <?>) type ;
458
- if ( JavaTypeHelper . isTemporal ( basicType .getExpressibleJavaType () ) ) {
458
+ if ( isTemporal ( basicType .getExpressibleJavaType () ) ) {
459
459
precisionToUse = getTemporalPrecision ();
460
460
lengthToUse = null ;
461
461
scaleToUse = null ;
@@ -465,7 +465,7 @@ Size calculateColumnSize(Dialect dialect, Mapping mapping) {
465
465
throw new AssertionFailure ( "no typing information available to determine column size" );
466
466
}
467
467
final JdbcMapping jdbcMapping = (JdbcMapping ) type ;
468
- Size size = dialect .getSizeStrategy ().resolveSize (
468
+ final Size size = dialect .getSizeStrategy ().resolveSize (
469
469
jdbcMapping .getJdbcType (),
470
470
jdbcMapping .getJdbcJavaType (),
471
471
precisionToUse ,
0 commit comments