HHH-9286 - AbstractStandardBasicType implements ProcedureParameterNamedBinder
This commit is contained in:
parent
2a43387081
commit
22dc33ff79
|
@ -32,7 +32,7 @@ import org.hibernate.type.descriptor.sql.SqlTypeDescriptor;
|
|||
* @author Brett Meyer
|
||||
*/
|
||||
public abstract class AbstractStandardBasicType<T>
|
||||
implements BasicType, StringRepresentableType<T>, ProcedureParameterExtractionAware<T> {
|
||||
implements BasicType, StringRepresentableType<T>, ProcedureParameterExtractionAware<T>, ProcedureParameterNamedBinder {
|
||||
|
||||
private static final Size DEFAULT_SIZE = new Size( 19, 2, 255, Size.LobMultiplier.NONE ); // to match legacy behavior
|
||||
private final Size dictatedSize = new Size();
|
||||
|
@ -348,4 +348,19 @@ public abstract class AbstractStandardBasicType<T>
|
|||
session.getWrapperOptions()
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void nullSafeSet(
|
||||
CallableStatement st, Object value, String name, SessionImplementor session) throws SQLException {
|
||||
nullSafeSet( st, value, name, session.getWrapperOptions() );
|
||||
}
|
||||
|
||||
protected final void nullSafeSet(CallableStatement st, Object value, String name, WrapperOptions options) throws SQLException {
|
||||
remapSqlTypeDescriptor( options ).getBinder( javaTypeDescriptor ).bind( st, ( T ) value, name, options );
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canDoSetting() {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue