if (Collection.class.isAssignableFrom(type)) {
obj = ResultObjectFactoryUtil.createObjectThroughFactory(type);
PROBE.setObject(resultObject, propertyName, obj);
}
} catch (Exception e) {
throw new SqlMapException("Error instantiating collection property for mapping '" + mapping.getPropertyName() + "'. Cause: " + e, e);
}
}
values = resultMap.getResults(statementScope, statementScope.getResultSet());
if (statementScope.isRowDataFound()) {
Object o = resultMap.setResultObjectValues(statementScope, null, values);
if (o != NO_VALUE) {
if (obj != null && obj instanceof Collection) {
((Collection) obj).add(o);
} else {
PROBE.setObject(resultObject, propertyName, o);
}
}
}
} catch (SQLException e) {
throw new SqlMapException("Error getting nested result map values for '" + mapping.getPropertyName() + "'. Cause: " + e, e);
}
}