}
return result;
}
private static void checkStoredProcedures() {
AppException errors = new AppException();
Enumeration allSqlIds = fSqlProperties.propertyNames();
while (allSqlIds.hasMoreElements()) {
String sqlId = (String)allSqlIds.nextElement();
String sql = (String)fSqlProperties.get(sqlId);
if (sql.startsWith(fUNSUPPORTED_STORED_PROC)) {
errors.add(
"The stored procedured called " + Util.quote(sqlId) + " has an explict return "
+ "value since it begins with " + fUNSUPPORTED_STORED_PROC + ". "
+ "A *.sql file can contain stored procedures, but only if they do not "
+ "have any OUT or INOUT parameters, including *explicit* return values (which "
+ "would need registration as an OUT parameter). See hirondelle.web4j.database "
+ "package overview for more information."
);
}
}
if (errors.isNotEmpty()) { throw new IllegalStateException(errors.getMessages().toString()); }
}