Code example for AbstractSingleColumnStandardBasicType

Methods: sqlType

0
    } 
 
    public void nullSafeSet(PreparedStatement st, Object value, int index) throws HibernateException, SQLException {
        try { 
            if (value == null) { 
                st.setNull(index, ((AbstractSingleColumnStandardBasicType<?>) type).sqlType());
            } 
            else { 
                Object identifier = value instanceof String ? value : identifierMethod.invoke(value, new Object[0]);
                type.nullSafeSet(st, identifier, index, null);
            } 
        } 
        catch (Exception e) {
            throw new HibernateException("Exception while invoking identifierMethod '" + identifierMethod.getName() + "' of " +
                    "enumeration class '" + enumClass + "'", e);
        } 
    } 
 
    public int[] sqlTypes() { 
        return sqlTypes;