JdbcMapper allow wildcards for java.sql.ResultSet
This commit is contained in:
parent
62bf29dc2b
commit
943ac3ac85
|
@ -601,11 +601,14 @@ public class JdbcMapperProcessor extends AbstractProcessor {
|
||||||
processingEnv.getMessager().printMessage(Diagnostic.Kind.ERROR, "@JdbcMapper.SQL sql parsed no column names, proper SQL? Wildcard? or bad parser?", methodElement);
|
processingEnv.getMessager().printMessage(Diagnostic.Kind.ERROR, "@JdbcMapper.SQL sql parsed no column names, proper SQL? Wildcard? or bad parser?", methodElement);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
for (final String key : keys)
|
// wildcards are fine for java.sql.ResultSet and nothing else
|
||||||
if ("*".equals(key)) {
|
if (!"java.sql.ResultSet".equals(returnType)) {
|
||||||
processingEnv.getMessager().printMessage(Diagnostic.Kind.ERROR, "@JdbcMapper.SQL sql parsed a wildcard column name which is not supported", methodElement);
|
for (final String key : keys)
|
||||||
return false;
|
if ("*".equals(key)) {
|
||||||
}
|
processingEnv.getMessager().printMessage(Diagnostic.Kind.ERROR, "@JdbcMapper.SQL sql parsed a wildcard column name which is not supported", methodElement);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
closeRs = rsm.mapToResultType(w, keys, eeMethod, maxRows, calendarName, cleanerName, !cachePreparedStatements, allowReflection ? reflectionFields : null);
|
closeRs = rsm.mapToResultType(w, keys, eeMethod, maxRows, calendarName, cleanerName, !cachePreparedStatements, allowReflection ? reflectionFields : null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue