@Override
public void nullSafeSet(Tuple resultset, Object value, String[] names, boolean[] settable, SharedSessionContractImplementor session)
throws HibernateException {
Object[] subvalues = nullSafeGetValues( value, componentType.getEntityMode() );
int columnCurrentIndex = 0;
for ( int i = 0; i < propertySpan; i++ ) {
int columnSpanOnProperty = propertyTypes[i].getColumnSpan( session.getFactory() );
if ( columnSpanOnProperty == 0 ) {
}
else if ( columnSpanOnProperty == 1 ) {
if ( settable[columnCurrentIndex] ) {
propertyTypes[i].nullSafeSet( resultset, subvalues[i], new String[] { names[columnCurrentIndex] }, session );
}
}
else {
final boolean[] subsettable = new boolean[columnSpanOnProperty];
System.arraycopy( settable, columnCurrentIndex, subsettable, 0, columnSpanOnProperty );
final String[] subnames = new String[columnSpanOnProperty];
System.arraycopy( names, columnCurrentIndex, subnames, 0, columnSpanOnProperty );
propertyTypes[i].nullSafeSet( resultset, subvalues[i], subnames, subsettable, session );
}
columnCurrentIndex += columnSpanOnProperty;
}
}