boolean foundValues = false;
final List<Class> parameterTypes = new ArrayList<Class>();
final List<Object> parameterValues = new ArrayList<Object>();
for (ResultMapping constructorMapping : constructorMappings) {
final Class parameterType = constructorMapping.getJavaType();
final TypeHandler typeHandler = constructorMapping.getTypeHandler();
final String column = constructorMapping.getColumn();
final Object value = typeHandler.getResult(rs, column);
parameterTypes.add(parameterType);
parameterValues.add(value);
foundValues = value != null || foundValues;
}
return foundValues ? objectFactory.create(resultType, parameterTypes, parameterValues) : null;